Skip to content

Commit b1d722f

Browse files
committed
Ensure shadow-inherit inherits the shadow color
1 parent cdecb55 commit b1d722f

File tree

2 files changed

+7
-6
lines changed

2 files changed

+7
-6
lines changed

packages/tailwindcss/src/utilities.test.ts

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -23968,12 +23968,6 @@ test('shadow', async () => {
2396823968
--tw-shadow-color: inherit;
2396923969
}
2397023970

23971-
@supports (color: color-mix(in lab, red, red)) {
23972-
.shadow-inherit {
23973-
--tw-shadow-color: color-mix(in oklab, inherit var(--tw-shadow-alpha), transparent);
23974-
}
23975-
}
23976-
2397723971
.shadow-red-500 {
2397823972
--tw-shadow-color: #ef4444;
2397923973
}

packages/tailwindcss/src/utilities.ts

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5275,6 +5275,13 @@ export function createUtilities(theme: Theme) {
52755275
decl('--tw-shadow', nullShadow),
52765276
decl('box-shadow', cssBoxShadowValue),
52775277
]
5278+
5279+
case 'inherit':
5280+
if (candidate.modifier) return
5281+
return [
5282+
boxShadowProperties(),
5283+
decl('--tw-shadow-color', 'inherit'),
5284+
]
52785285
}
52795286

52805287
// Shadow size

0 commit comments

Comments
 (0)