[Resolved] Button Aria Label

Home Forums Support [Resolved] Button Aria Label

Home Forums Support Button Aria Label

Viewing 10 posts - 1 through 10 (of 10 total)
  • Author
    Posts
  • #1346756
    Andy

    Hi, I understand there is an aria-label attribute in the buttons in GenerateBlocks, but can I get some clarification on how to set a label? For example, I know I can add text to a button e.g ‘find out more’, but if I want to use an aria-label for screen reader users such as “Visit the case study page”, how would I go about doing that? I have tried editing the button in html and adding an aria-label but keep getting the following message: “this block contains unexpected or invalid content”.

    #1346847
    David
    Staff
    Customer Support

    Hi there,

    Generally an Aria field is only required if the element doesn’t have a clear label/heading.

    Which is why the Buttons aria field is only available in the Icon settings after an icon is added and the option to hide the text is selected.

    I’ll pass this onto Tom, there may be a filter to display it alway. If there isn’t then you would need to use a HTML block to write your own button.

    #1347315
    Tom
    Lead Developer
    Lead Developer

    Hi there,

    I agree that it should always be an option – even buttons with text can require an aria-label.

    I’ve moved the option into the Advanced panel in 1.1 🙂

    #1347342
    Andy

    That’s fantastic. Thanks Tom!

    #1347507
    Tom
    Lead Developer
    Lead Developer

    No problem! Thanks for the suggestion 🙂

    #1416705
    jose

    Hi! I added manually <button class="menu-toggle" aria-controls="primary-menu" aria-expanded="false" aria-label="top left"> in inc/structure/navigation.php

    How can I use it from child theme?
    In my child theme I create inc/structure/navigation.php but doesnt work. THX

    #1416729
    Leo
    Staff
    Customer Support

    Any chance you can open a new topic for your question?

    Thanks!

    #1833417
    Oliver

    Kann ich das ARIA-Label vom Logo im Menü editieren?

    #1833716
    David
    Staff
    Customer Support

    Hi there,

    this is an old topic – can you raise a new topic where we can assist.

    #1833727
    Oliver

    Hallo David,

    ich habe unter der Nummer #1833724 ein neues Thema geöffnet.

Viewing 10 posts - 1 through 10 (of 10 total)
  • You must be logged in to reply to this topic.