Skip to content

feat(a11y): use list-style-stype instead of list-style none to avoid losing semantic role in Safari #41651

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Draft
wants to merge 1 commit into
base: main
Choose a base branch
from
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
feat: use list-style-stype instead of list-style none to avoid losing…
… semantic role in Safari
  • Loading branch information
MaxLardenois committed Aug 8, 2025
commit ab59be9413076cb02be18ad5ff1ac76910028c73
2 changes: 1 addition & 1 deletion scss/_breadcrumb.scss
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
padding: var(--#{$prefix}breadcrumb-padding-y) var(--#{$prefix}breadcrumb-padding-x);
margin-bottom: var(--#{$prefix}breadcrumb-margin-bottom);
@include font-size(var(--#{$prefix}breadcrumb-font-size));
list-style: none;
list-style-type: "";
background-color: var(--#{$prefix}breadcrumb-bg);
@include border-radius(var(--#{$prefix}breadcrumb-border-radius));
}
Expand Down
2 changes: 1 addition & 1 deletion scss/_dropdown.scss
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@
@include font-size(var(--#{$prefix}dropdown-font-size));
color: var(--#{$prefix}dropdown-color);
text-align: left; // Ensures proper alignment if parent has it changed (e.g., modal footer)
list-style: none;
list-style-type: "";
background-color: var(--#{$prefix}dropdown-bg);
background-clip: padding-box;
border: var(--#{$prefix}dropdown-border-width) solid var(--#{$prefix}dropdown-border-color);
Expand Down
2 changes: 1 addition & 1 deletion scss/_list-group.scss
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@
display: flex;
flex-direction: column;

// No need to set list-style: none; since .list-group-item is block level
// No need to set list-style-type: ""; since .list-group-item is block level
padding-left: 0; // reset padding because ul and ol
margin-bottom: 0;
@include border-radius(var(--#{$prefix}list-group-border-radius));
Expand Down
2 changes: 1 addition & 1 deletion scss/_nav.scss
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
flex-wrap: wrap;
padding-left: 0;
margin-bottom: 0;
list-style: none;
list-style-type: "";
}

.nav-link {
Expand Down
2 changes: 1 addition & 1 deletion scss/_navbar.scss
Original file line number Diff line number Diff line change
Expand Up @@ -98,7 +98,7 @@
flex-direction: column; // cannot use `inherit` to get the `.navbar`s value
padding-left: 0;
margin-bottom: 0;
list-style: none;
list-style-type: "";

.nav-link {
&.active,
Expand Down
2 changes: 1 addition & 1 deletion scss/mixins/_lists.scss
Original file line number Diff line number Diff line change
Expand Up @@ -3,5 +3,5 @@
// Unstyled keeps list items block level, just removes default browser padding and list-style
@mixin list-unstyled {
padding-left: 0;
list-style: none;
list-style-type: "";
}