Viewing 8 posts - 1 through 8 (of 8 total)
  • Author
    Posts
  • #1489050

    I’d like to insert placeholder text so that Google Insight doesn’t report an accessibility error on my slider arrows. Do you have a CSS solution? I’ve found HTML solutions online, but I don’t know if we can modify the HTML to Enfold Child.

    Here’s the error reported by Google Insight:

    Links don’t have visible names
    Write visible and unique text for links (and for image placeholder text, if you use it in links) so that screen reader users can easily position the cursor over them and enjoy a better browsing experience. Learn how to make links accessible.
    Non-compliant elements
    Here’s the error reported by Google Insight :

    div#wrap_all > div#main > div.avia-fullscreen-slider > a.scroll-down-link

    #1489078

    Hi!

    Thank you for the inquiry.

    Looks like the report is referring to the scroll-down link. Please create a test page and provide the link in the private field so we can check the slider element further — screenshots will also help.

    Best regards,
    Ismael

    #1489082

    Voici un page test avec le donwn-link :

    #1489155

    Hi,

    Thank you for the update.

    Try to add this code to the functions.php file to include a < title > element inside the scroll-down svg image.

    add_action( 'wp_footer', 'ava_script_mod', 9999 );
    function ava_script_mod() {
        ?>
        <script type="text/javascript">
        jQuery(document).ready(function($) {
            $('.scroll-down-link svg').each(function () {
                $(this).find('title').remove();
    
                $(this).prepend('<title>Scroll down</title>');
            });
        });
        </script>
        <?php
    }

    Let us know the result.

    Best regards,
    Ismael

    #1489182

    Hi, thanks for this answer, I just injected it into my function.php, but google insight still tells me the accessibility error:

    Links don’t have visible names
    Write visible and unique text for links (and for image placeholder text, if you use it in links) so that screen reader users can easily position the cursor over them and enjoy a better browsing experience. Learn how to make links accessible.

    https://pagespeed.web.dev/analysis/https-kerry-han-fr-test/2s8d8rqqkp?hl=fr&form_factor=mobile

    #1489190

    i think google likes to see an aria-label on that links.

    function ava_script_mod() {
    ?>
    <script type="text/javascript">
    jQuery(function($){
      $('.scroll-down-link').each(function() {
        $(this).attr('aria-label', 'Passer à la section suivante');
      });
    });
    </script>
    <?php
    }
    add_action( 'wp_footer', 'ava_script_mod', 9999 );

    by the way this:

    jQuery(function($){
    // is shorthand for 
    jQuery(document).ready(function($) {
    #1489194

    Thank you, it works perfectly, you can close this ticket

    #1489239

    Hi,

    Great! Glad to know that the issue has been resolved. Please feel free to open another thread if you have more questions.

    Have a nice day.

    Best regards,
    Ismael

Viewing 8 posts - 1 through 8 (of 8 total)
  • The topic ‘name visible on .scroll-down-link’ is closed to new replies.