yatil,
@yatil@yatil.social avatar

This was a fun Codepen to put together (no documentation) for coding a shipping status indicator. I don’t get my hands on code often, so this was a neat opportunity to do nesting and media query short syntax, and combine it with the currentcolor keyword and do some pseudo elements shenanigans.

https://codepen.io/yatil/pen/rNRKMXj

yatil,
@yatil@yatil.social avatar

This also demonstrates how hard it is to have color separation between the past and the current state – current is a color which I find having not extreme contrast to the white background. The past ones are , the minimum contrast to white for text. But the difference between and is less than 3:1 which would be the minimum if there were no other indicators for the current item (but there are, bold + filled circles)

Also, why no aria-current: https://yatil.social/@yatil/111879248472421124

joelanman,
@joelanman@hachyderm.io avatar

@yatil Is aria-current helpful for something like this or not?

yatil,
@yatil@yatil.social avatar
simevidas,
@simevidas@mastodon.social avatar

@yatil It would be useful if HTML had an element for list caption or heading (like how <table> has <caption>). If I were a screen reader user, I would want this list to be announced with a label, e.g., “parcel tracking, list, 4 items”, before it starts speaking the items.

yatil,
@yatil@yatil.social avatar

@simevidas You can put a heading before the list. I didn’t include it because the placement is usually self-explanatory.

simevidas,
@simevidas@mastodon.social avatar

@yatil The developer may not want to add a heading to the document structure just for such a list. It would be better if there was a standard way to add a local heading or caption only for the purposes of labelling the list.

yatil,
@yatil@yatil.social avatar

@simevidas Either you need such a label or not. If you need it, you can use headings or aria groups or whatever, there are loads of options already.

aardrian,
@aardrian@toot.cafe avatar

@simevidas

> If I were a screen reader user, I would want this list to be announced with a label, e.g., “parcel tracking, list, 4 items”, before it starts speaking the items.

I encourage you to be careful asserting what would be useful to screen reader users by speculating what you, a not-daily-SR user, might want — without the benefit of the lived experience or their explicit feedback.

This is less about your post and more about my experience seeing this happen regularly.

@yatil

simevidas,
@simevidas@mastodon.social avatar

@aardrian @yatil Well, the web is a very open platform where anyone can publish, so naturally there’s going to be a lot of content that doesn’t receive feedback from SR users. That’s just reality. That’s why it’s important to make creating accessible web content as easy as possible. ARIA is good, but standard HTML is better. I think a standard element for labelling lists would be useful.

aardrian,
@aardrian@toot.cafe avatar

@yatil Any reason you went with the hidden text versus aria-current? Not a judgement, just curious.

ekelseya,

@aardrian @yatil That piques my curiosity; which do you prefer?

aardrian,
@aardrian@toot.cafe avatar

@ekelseya
I prefer neither. They are both valid methods.

Visually hidden text works when the CSS is stripped and the visual cues are lost.

aria-current is less verbose and depends on support.

So it comes down to knowing the use case(s) and audience.

@yatil

yatil,
@yatil@yatil.social avatar

@aardrian I don’t like states on non-interactive elements. If this was navigable, I certainly would put it on the button/link, but just on an <li>, I’m not a big fan. (Possibly irrational.) Plus I wanted to make past steps clear as well, and there is nothing in ARIA for that, so I like to err on the side of consistency.

aardrian,
@aardrian@toot.cafe avatar

@yatil Thanks!

  • All
  • Subscribed
  • Moderated
  • Favorites
  • random
  • DreamBathrooms
  • mdbf
  • ethstaker
  • magazineikmin
  • GTA5RPClips
  • rosin
  • thenastyranch
  • Youngstown
  • osvaldo12
  • slotface
  • khanakhh
  • kavyap
  • InstantRegret
  • Durango
  • provamag3
  • everett
  • cisconetworking
  • Leos
  • normalnudes
  • cubers
  • modclub
  • ngwrru68w68
  • tacticalgear
  • megavids
  • anitta
  • tester
  • JUstTest
  • lostlight
  • All magazines