Supporting user preferences on your sites and apps

Back in July, I wrote about how I rolled out an improved dark mode for my website.
I discussed how the prefers-color-scheme media query can be used to support a user’s choices in their operating system. I also shared some tips for making sure your color choices have proper contrast using WebAIM’s color contrast tool.
/** * If dark mode is enabled, do this instead */ @media (prefers-color-scheme: dark) { /* .


This content originally appeared on Go Make Things and was authored by Go Make Things

Back in July, I wrote about how I rolled out an improved dark mode for my website.

I discussed how the prefers-color-scheme media query can be used to support a user’s choices in their operating system. I also shared some tips for making sure your color choices have proper contrast using WebAIM’s color contrast tool.

/**
 * If dark mode is enabled, do this instead
 */
@media (prefers-color-scheme: dark) {
	/* ... */
}

Last week, inclusive design advocate (and personal friend) Eric Bailey shared an article he wrote about a variety of OS-level choices a user can make that are (or soon will be) detectable with media queries.

Among my favorites are…

  • Reducing motion and animations (which I’ve written about before here)
  • Reducing data usage, which will be really useful for serving smaller assets on low bandwidth or low data devices
  • Contrast mode
  • Transparency, to disable or reduce transparent graphics

Eric’s whole article is a good introduction to thoughtful, user-focused design. Give it a read!

⏰? Early Bird Sale! A new session of the Vanilla JS Academy starts on October 4. This week, get 35% off the program. Click here to join.


This content originally appeared on Go Make Things and was authored by Go Make Things


Print Share Comment Cite Upload Translate Updates
APA

Go Make Things | Sciencx (2021-09-14T14:30:00+00:00) Supporting user preferences on your sites and apps. Retrieved from https://www.scien.cx/2021/09/14/supporting-user-preferences-on-your-sites-and-apps/

MLA
" » Supporting user preferences on your sites and apps." Go Make Things | Sciencx - Tuesday September 14, 2021, https://www.scien.cx/2021/09/14/supporting-user-preferences-on-your-sites-and-apps/
HARVARD
Go Make Things | Sciencx Tuesday September 14, 2021 » Supporting user preferences on your sites and apps., viewed ,<https://www.scien.cx/2021/09/14/supporting-user-preferences-on-your-sites-and-apps/>
VANCOUVER
Go Make Things | Sciencx - » Supporting user preferences on your sites and apps. [Internet]. [Accessed ]. Available from: https://www.scien.cx/2021/09/14/supporting-user-preferences-on-your-sites-and-apps/
CHICAGO
" » Supporting user preferences on your sites and apps." Go Make Things | Sciencx - Accessed . https://www.scien.cx/2021/09/14/supporting-user-preferences-on-your-sites-and-apps/
IEEE
" » Supporting user preferences on your sites and apps." Go Make Things | Sciencx [Online]. Available: https://www.scien.cx/2021/09/14/supporting-user-preferences-on-your-sites-and-apps/. [Accessed: ]
rf:citation
» Supporting user preferences on your sites and apps | Go Make Things | Sciencx | https://www.scien.cx/2021/09/14/supporting-user-preferences-on-your-sites-and-apps/ |

Please log in to upload a file.




There are no updates yet.
Click the Upload button above to add an update.

You must be logged in to translate posts. Please log in or register.