Skip to content

Commit 7b45ef4

Browse files
committed
Use grid over flexbox for CardWrapper in Safari v11-v14.0
1 parent 35635e3 commit 7b45ef4

File tree

1 file changed

+7
-5
lines changed

1 file changed

+7
-5
lines changed

dotcom-rendering/src/components/Card/components/CardWrapper.tsx

Lines changed: 7 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -23,18 +23,20 @@ const baseCardStyles = css`
2323
/* We absolutely position the faux link so this is required here */
2424
position: relative;
2525
26-
/* Target Safari 10.1 */
27-
/* https://www.browserstack.com/guide/create-browser-specific-css */
26+
/*
27+
* Target Safari 10.1 to 14.0
28+
* https://www.browserstack.com/guide/create-browser-specific-css
29+
* Flexbox with gap is not supported until Safari 14.1
30+
*/
2831
@media not all and (min-resolution: 0.001dpcm) {
29-
@supports (-webkit-appearance: none) and
30-
(not (stroke-color: transparent)) {
32+
@supports (-webkit-appearance: none) and (not (display: flex; gap: 1em)) {
3133
display: grid;
3234
grid-auto-rows: min-content;
3335
align-content: start;
3436
}
3537
}
3638
37-
/* a tag specific styles */
39+
/* <a /> tag specific styles */
3840
color: inherit;
3941
text-decoration: none;
4042
`;

0 commit comments

Comments
 (0)