<?php
// Temporary fix to remove accessibility attributes from the Pager facets "dots" element.
add_action( 'facetwp_scripts', function() {
?>
<script>
(function($) {
if ('undefined' !== typeof FWP.hooks) {
FWP.hooks.addAction('facetwp/loaded', function() {
$('.facetwp-page').each(function() {
let el = $(this);
if (el.hasClass('dots')) {
el.nodes[0].removeAttribute('role');
el.nodes[0].removeAttribute('aria-label');
el.nodes[0].removeAttribute('tabindex');
}
});
}, 1000);
}
})(fUtil);
</script>
<?php
}, 100 );