update bootstrap modal close button (X) - 508 issue

update bootstrap modal close button (X) - 508 issue

wblakencwblakenc Posts: 78Questions: 17Answers: 1

Hello,
I am trying to update my application to be as 508 compliant as possible. One thing the tester found is the 'X' on the modal does not have a label or description so when a screen reader gets to that point it says: "bimes button" instead of close button. This seems like it should be a simple change, but I do not see an API option to update that piece of the modal. Am I missing something or is this piece of the modal not configurable using the editor API? If it is not customizable, is the modal created in source code somewhere that I can manually update? I would rather not change the source, but if it is my only option that will have to do.

Suggestions? Thoughts? Thanks!

This question has an accepted answers - jump to answer

Answers

  • wblakencwblakenc Posts: 78Questions: 17Answers: 1

    In case it matters, I am using Bootstrap 4 to style my site and editor/datatables.

  • allanallan Posts: 63,498Questions: 1Answers: 10,471 Site admin
    Answer ✓

    That's a good point - thank you. There currently isn't a way to customise the close button through Editor's own API but it can readily be done with a little DOM / jQuery:

    $('button.close', editor.displayNode()).attr('title', 'Close');
    

    I'll file an issue so we can that into our API for the next release.

    Allan

  • wblakencwblakenc Posts: 78Questions: 17Answers: 1

    Thanks Allen! I should have been able to figure that out. I appreciate it.

  • allanallan Posts: 63,498Questions: 1Answers: 10,471 Site admin

    Thinking about it - using the aria-label attribute might be better than title. That's what we'll do when this goes into Editor.

    Allan

  • colincolin Posts: 15,240Questions: 1Answers: 2,599

    Just to say Allan went with your title approach, and this will be in the next Editor release, probably 1.9.3, due out in the next couple of days.

    Colin

This discussion has been closed.