Bug 37054 would benefit from a color contrast checker. I have created something in JavaScipt. I would like to know if people would prefer using a JS library, or if it would be OK to use something we wrote ourselves?
This thing might not be the worst one: https://www.npmjs.com/package/color-contrast?activeTab=code Good thing is that it is small and only has a single dependency, last commit was 5 years ago, though.