ckan / ckanext-spatial

Geospatial extension for CKAN
http://docs.ckan.org/projects/ckanext-spatial
126 stars 193 forks source link

Feature request: spatial facet keyboard accessibility #148

Open MrkGrgsn opened 8 years ago

MrkGrgsn commented 8 years ago

I wanted to start a conversation about adding keyboard accessibility to the Filter by location facet. We're currently working with a government client with a WCAG AA compliance requirement and so we've been asked to make the spatial facet keyboard accessible. I guess governments with similar accessibility requirements form a reasonable portion of CKAN's market so this might be valuable as a core feature of ckanext-spatial.

Keyboard accessibility is a WCAG Level A requirement. Currently, it is possible to zoom the map and it is also possible to pan, although it is more-or-less a hidden feature. It is not possible to define a spatial extent to apply (or at least, it's not obvious and I can't work out how to do it).

After some discussion here, we've come up with the following proposal:

  1. Add an explicit keyboard accessible pan
  2. Add text fields for defining an extent bounding box using lat and long to the expanded view.
  3. Add a button to define the extent based on the current map view --- helps user to define an initial extent when they don't know the lat and long
  4. The map extent and bounding box fields are synchronised, i.e., when one is changed the other is updated --- provides visual feedback on lat and long entered
  5. When no extent is selected, replace the map with a link/button labelled like 'Select area of interest' which is formatted consistent with other facets --- provides clear instruction on how to start --- when clicked shows popup with expanded map and bounding box fields, similar to current expanded view.
  6. When an extent is selected, a non-interactive map is shown in the facet sidebar, with formatting to match other facets more closely

That's a little hard to visualise; I'll try to get some mockups done.

I'm also aware that @florianm has been working on some enhanced extent input widgets (#11). I don't think this work would touch on what he's doing but pinging him just in case. Also extent input widgets with greater precision will be in our future also and it will be best if those are accessible too.

MrkGrgsn commented 8 years ago

Some mockups to illustrate the idea.

  1. No location facet applied

mockup_step_01

  1. User clicks on facet link and popup is displayed

mockup_step_02

  1. Extent is selected using map or form

mockup_step_03

  1. Extent is applied

mockup_step_04

MrkGrgsn commented 8 years ago

I think it got lost in my original post, so to make it clear, Link Digital is happy to implement this pending approval from our client.

davidread commented 8 years ago

Lots of really good stuff here from my point of view. Really great that you are improving this feature and funding it too.

One thing that might be worth discussing is how you present the coordinates - I've never been particularly convinced about lat/long being too prominent. Long numbers put off many users and distract from the task. The use case for even a geo geek to see or input these numbers just seems so niche to me. e.g. they want data for a particular fishing area in the sea that they know about, but the background map doesn't mark it. Even so, they can just manually select the rough bit of sea they want - that's probably good enough, since they are going to be selecting the dataset by hand in the next step anyway. So maybe consider hiding the lat/long selectors by default, exposing them with a button, unless you have good evidence for showing it by default?

MrkGrgsn commented 8 years ago

Thanks for feedback, David. Our client is happy with the approach above and we've been given approval to start.

To be honest, I agree with you about the value of lat and long for this use case. We're leaning that way because a) the interaction of a simple form is more conventional for users compared with other options for defining the extent with keys b) it's simple to implement and c) our client is familiar with this style of form in similar applications they use. That said, our designer thinking about the best way to make the fields not visible by default.

amercader commented 8 years ago

I agree with @davidread that the use case for this is very specific. Another option if you don't want to add the extra complexity of displaying/hiding the coordinate fields is to just override the search form on your own CKAN extension to suit your client requirements.

davidread commented 8 years ago

Yeah I'm keen to see this work go into ckanext-spatial. So perhaps Adria or I will add a way to add a show/hide button for the coordinates, then that might well suit everyone.

Engerrs commented 7 years ago

Hi @amercader , @davidread . I've added a PR for spatial facet keyboard accessibility, can you please take a look.

markstuart commented 1 year ago

Hi @Engerrs @davidread, this same issue has cropped up for us in an accessibility audit as well... looks like this may have fallen off the radar?

Any chance of moving this forward? We can look at pulling in the work done by @Engerrs into our own extension in the interim obviously.

davidread commented 1 year ago

@markstuart I'm no longer involved - best you contact the current Tech Team

markstuart commented 1 year ago

Thanks David, apologies for tagging you, wasn't sure who was the right person for this.

@amercader is this something you can help with? I guess the original branch would need to be brought in line with the current state of master, let me know if there's anything I can help with.