1

I am improving the accessibility of a website to make sure users can easily navigate using the keyboard only. There is a button that generates a file, but after clicking on the button, the generic browser download dialog appears at the bottom of the page, and the focus still stays on the button. Users with a screen reader are not notified about the dialog. There is a way to focus on the dialog when it appears?

I am able to focus on elements of the page, but since the dialog is a browser feature, I have no idea how to do it!?

I will appreciate any guidance what can you give me. Thank you!

The dialog looks like this in Internet Explorer

react_or_angluar
  • 1,568
  • 2
  • 13
  • 20
Catherine
  • 13
  • 2
  • This can be your solution? [Solved: File Download Dialog, Save As in Internet Explorer 11 - Micro Focus Community - 1728015](https://community.microfocus.com/t5/Silk-Test-User-Discussions/File-Download-Dialog-Save-As-in-Internet-Explorer-11/m-p/1728015) – eapo Dec 16 '20 at 21:26
  • Is there an audible noise that most users recognize when this happens? – react_or_angluar Dec 17 '20 at 09:47

1 Answers1

0

You do not have control to do this, plus this is expected behaviour and there is nothing you need to do.

Screen reader users will go out of the active screen using shortcut keys if they wish to access the file.

Other considerations as you said "button" in your question

You should not use a <button> element to generate a file. File downloads should always be a hyperlink (<a>).

If the document requires variables to be passed and you are able to pass them via a GET request then the hyperlink href should be the URL + GET parameters.

The advantage of this for everyone is that they can middle click to open the document in a new window (or right click and choose "open in new window" etc.), plus it works without JavaScript and is easily indexed by Search Engines.

Also adding the download attribute to a hyperlink has some advantages, especially as in some screen readers it gets signalled to users that this link will download a document.

When creating a download link you should state the document type (pdf, word etc.) and document size for accessibility. You can do this with visually hidden text if your design does not allow for it.

I have written a reasonably in-depth answer on how to add the file size and file type info for screen readers here. About 70% of it is relevant to you.

GrahamTheDev
  • 22,724
  • 2
  • 32
  • 64