If you’re trying to be darkmode friendly, you should try using something dark for the background with light text, because this only achieves a bad contrast ratio, and it is actually worse for most of the people looking at it.
Usually, they use a light grey instead of white, so the text doesn’t become overly bright, but not yellow, that’s usually reserved for highlights or similiar effects, except when in „High contrast mode”, when they use yellow for text/outlines and black as a background
If you’re trying to be darkmode friendly, you should try using something dark for the background with light text, because this only achieves a bad contrast ratio, and it is actually worse for most of the people looking at it.
https://developer.mozilla.org/en-US/docs/Web/Accessibility/Understanding_WCAG/Perceivable/Color_contrast
https://coolors.co/contrast-checker/222222-efefef
thanks. will consider this next time
For a grey background, yellow text is usually preferred.
Usually, they use a light grey instead of white, so the text doesn’t become overly bright, but not yellow, that’s usually reserved for highlights or similiar effects, except when in „High contrast mode”, when they use yellow for text/outlines and black as a background