livingstoneonline / onemorevoice

This is the repository for One More Voice. One More Voice is a digital humanities recovery project that identifies, documents, and critically engages with the voices of racialized creators in British imperial and colonial archives. The voices take multiple forms and appear in multiple genres. Our project seeks to introduce these rich and diverse materials to broad academic and public audiences. Recourse to the voices promises to transform our understanding of imperial and colonial history and literature while foregrounding perspectives that scholarship in majority has hitherto overlooked or silenced.
http://onemorevoice.org
3 stars 0 forks source link

Reliance on JavaScript #4

Closed jduss4 closed 3 years ago

jduss4 commented 3 years ago

I think that this site, in an effort to use HTML rather than PHP or a static site generator, etc, is leaning very heavily on JavaScript to pull in content like footers, and create navigation. If you disable JavaScript, which is not an uncommon situation to be in for people with screen readers or even just people like Greg who do it to disable advertisements, the site is no longer usable.

See https://github.com/livingstoneonline/onemorevoice/issues/3 for some ideas of how this JS use could be avoided by committing to different tech.

awisnicki commented 3 years ago

@jduss4 I'm not yet to the point of addressing this issue, but I do have question in relation to what you write above. In general for OMV, when I need to develop a new component I often turn to the Index of ARIA Design Pattern Examples page and see if it has code that may be of interest.

This seems to me to be an authoritative resource, but I see that a significant portion of the examples there rely on Javascript. I don't have wide experience with screen readers, but this practice on the ARIA site – which, I take it, is partial geared towards enhancing accessibility for people who use screen readers – seems to run at odds with what you write above:

If you disable JavaScript, not an uncommon situation to be in for people with screen readers

Can you elaborate a bit?

jduss4 commented 3 years ago

Hi @awisnicki , sure. As screenreader technology improves, it may be becoming less of an issue, but basically if you are using JavaScript for presentation it's a good idea to think about how something would look if there was NO JavaScript.

So for example, when Karin is designing pages, she will do it in such a way that if you don't have JavaScript, something like a dropdown menu will start with all the dropdowns visible. If the page's javascript does load, it will hide the dropdown. This way, if someone didn't have JS, they'd have an ugly-ish way of getting to content, but if they do have JS nothing will look amiss. Basically, I guess if you think of hiding things with JS rather than adding things with JS, it ensures that people without JavaScript won't completely lose access to links, or a footer, etc.

awisnicki commented 3 years ago

Yes, this was a great suggestion as noted in #12. Thank you again! Here's a screenshot of how I set it up on the site.

Screenshot_2021-02-16 One More Voice Home

awisnicki commented 3 years ago

I'm reviewing this and hoped you might provide a quick clarification. At the point (though it's not yet live), I've solved the issue of being able to navigate the site if Javascript is disabled, as specified above. As a result, I think I might be able to close this issue. But before I do, can you clarify: Was your concern 1) the fact that I was relying on JavaScript for adding navigation elements and, if disabled, the site was no longer navigable or 2) that I was relying on JavaScript in general for adding some bits in general (i.e., not just related to navigation) and I should instead avoid JavaScript whenever possible. I think you meant option 1, but can you confirm?

jduss4 commented 3 years ago

Hi Adrian,

Yes, in general JS is fine to have but if the site is unusable without it then that becomes a problem. Now that your nav is being added regardless of JS status, I am a much happier camper. I am not sure that your header / footer will show up without JS, but those are also probably not critical to a user's experience accessing content on the site!

awisnicki commented 3 years ago

@jduss4 That's great to know, as indeed I've grown quite font of JavaScript (and JQuery) and am slowly starting to get better at it. Yes, the site is now fully usable without Javascript and header/footer, although ideal for user experience, decidedly not critical with the fallback nav setup, so I'm going to go ahead and close this issue. Thanks again for the help with it!