Skip to content
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

EPS-1121: Accessibility check in UAE Lite #1121

Open
wants to merge 1 commit into
base: release-candidate
Choose a base branch
from
Open
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
Original file line number Diff line number Diff line change
Expand Up @@ -777,7 +777,7 @@ protected function render():void {
$home_class = ( 'yes' === $settings['show_home'] ) ? 'hfe-breadcrumbs-show-home' : '';

// Build the breadcrumb output.
$output = '<ul class="hfe-breadcrumbs ' . esc_attr( $home_class ) . '">';
$output = '<nav aria-label="Breadcrumb"><ul class="hfe-breadcrumbs ' . esc_attr( $home_class ) . '">';
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nav is added as a wrapper to ul tag. Make sure we test this change with different themes. Mostly themes add CSS for nav elements.
@Bhikule19

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sure, will test this with multiple themes


foreach ( $breadcrumbs as $index => $breadcrumb ) {
// Open the breadcrumb item.
Expand All @@ -791,7 +791,7 @@ protected function render():void {
if ( $breadcrumb['url'] ) {
$output .= '<a href="' . esc_url( $breadcrumb['url'] ) . '"><span class="hfe-breadcrumbs-text">' . wp_kses_post( $breadcrumb['title'] ) . '</span></a>';
} else {
$output .= '<span class="hfe-breadcrumbs-text">' . wp_kses_post( $breadcrumb['title'] ) . '</span>';
$output .= '<span class="hfe-breadcrumbs-text" aria-current="page">' . wp_kses_post( $breadcrumb['title'] ) . '</span>';
}
$output .= '</li>';

Expand All @@ -810,7 +810,7 @@ protected function render():void {
$output .= '</li>';
}
}
$output .= '</ul>';
$output .= '</ul></nav>';

echo $output; // phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped

Expand Down
Loading