Skip to content

Commit 38dbc1a

Browse files
Ignore social links block in reset style selectors
1 parent 2296fc5 commit 38dbc1a

File tree

1 file changed

+9
-5
lines changed

1 file changed

+9
-5
lines changed

packages/block-library/src/reset.scss

Lines changed: 9 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -56,20 +56,24 @@
5656
margin: revert;
5757
}
5858

59-
ul,
60-
ol {
59+
// These resets ignore the social links block without increasing
60+
// specificity as the block library styles include their own reset. This
61+
// allows the block to have zero specificity styles and remain compatible
62+
// with global styles for block themes.
63+
ul:where(:not([class*="wp-block"])),
64+
ol:where(:not([class*="wp-block"])) {
6165
margin: revert;
6266
padding: revert;
6367
list-style-type: revert;
6468
box-sizing: border-box;
6569

6670
// Remove bottom margin from nested lists.
67-
ul,
68-
ol {
71+
ul:where(:not([class*="wp-block"])),
72+
ol:where(:not([class*="wp-block"])) {
6973
margin: revert;
7074
}
7175

72-
li {
76+
li:where(:not([class*="wp-block"])) {
7377
margin: revert;
7478
}
7579
}

0 commit comments

Comments
 (0)