DEV Community

Cover image for Quick update: Building a disability simulator [WIP]

Quick update: Building a disability simulator [WIP]

GrahamTheDev on March 31, 2021

Super quick post as this is a work in progress, but here are a couple of fiddles for a disability simulator I am building. Loads of redundant code...
Collapse
 
eekee profile image
Ethan Azariah

Nice that you're doing this. :) Personally, I'm especially glad to see there's a minimum contrast recommendation.

At the time I'm writing this:
The vision impairment simulator barely works in Firefox. Tunnel vision works, but the others just make the whole area white. Reset also makes the whole area white. Switching to one of the code tabs and back makes an effective reset.

Collapse
 
grahamthedev profile image
GrahamTheDev

I guess it will be a simple fix, Firefox might handle filter: brightness differently as I use that as a reset.

Thanks for letting me know as although this will be a chrome plugin I might as well fix that in case I release for Firefox too! ❤️

Collapse
 
grahamthedev profile image
GrahamTheDev • Edited

My best score in the "tremors simulator" is 42 attempts to 13 clicks - can you do better?

Collapse
 
afif profile image
Temani Afif

cheating I can do more clicks than attempts :p

dev-to-uploads.s3.amazonaws.com/up...

Collapse
 
grahamthedev profile image
GrahamTheDev

Ok I haven't managed to do that, i can only get level, so I will withdraw the honour system, high score! 🤣

Collapse
 
link2twenty profile image
Andrew Bone

You can tab to it and just hold enter 😉
But that doesn't really feel in the spirit of things

Collapse
 
grahamthedev profile image
GrahamTheDev

Yeah that was the cheat, you can also cheat with the mouse as when the “actual” hidden cursor is over the item you can see a hover effect and I cannot for the life of me get it to stop the propogation of the actual mouse event at the moment without an error.

Thread Thread
 
link2twenty profile image
Andrew Bone

A couple of edits to the html and css will fix that

Thread Thread
 
grahamthedev profile image
GrahamTheDev

Thanks for that but that wasn't the issue I had (although it makes the game more fair now! 🤣)

The problem is that the hidden cursor (the actual mouse position) is still clicking as well as my fake click. If you position the shaky cursor off to the left 50px and up about 50px you will still click the button.

However I can't stop that as everything I have tried either cause a stack size error or doesn't work?

The idea of this ultimately is to run on any page and so that one is an annoying one to fix!

Collapse
 
afif profile image
Temani Afif

I made 26 out of 105 attempts and now I have a headache ...

dev-to-uploads.s3.amazonaws.com/up...

Collapse
 
hellonehha profile image
Neha Sharma

This is so awesome.

Collapse
 
grahamthedev profile image
GrahamTheDev

Thanks Neha, eagerly awaiting your next interview questions instalment! 😁😁

Collapse
 
hellonehha profile image
Neha Sharma

Actually, I started something new today.

a11ytips.dev/interviews/

Let me know your thoughts

Thread Thread
 
grahamthedev profile image
GrahamTheDev

Awesome idea, I will have a proper look over weekend but the concept is great!

Also never checked your site out so will have a proper look around that too when get chance! 😍

Collapse
 
jonasjason profile image
Jonas Jason

This is awesome! I had 84 attempts for 20 clicks. Very frustrating and drives home the necessity of large buttons. Can't wait to see your finished product!

Collapse
 
grahamthedev profile image
GrahamTheDev

Thanks! Next instalment due early next week, hopefully you will find that one less frustrating but still useful. 😋