0

Hello I'm new to SharePoint, I created a theme using this tool. And Exported it using PowerShell

Primary: #6ebe49

Text color: #ffffff

Background color: #000000

The problem is, one of the section background shadings is white background and white text. Is there a way to make that background shading white background and black text?

2 Answers 2

0

Per my knowledge, when you use Fluent UI Theme Designer to create a modern theme, there is no option to change the color of some texts, it is an overall setting.

1
  • I see, is there a way to create a theme that I can modify the background shadings?
    – markyeoj
    Jun 9, 2021 at 19:39
0

Easy answer: Use the prefers-color-scheme CSS media feature.
See here:

https://developer.mozilla.org/en-US/docs/Web/CSS/@media/prefers-color-scheme

Examples: Create two css rules as per below and put them at the bottom of the last style sheet that is loaded (or put them into the HTML - below the style sheets) so as to override:

Dark Theme @media (prefers-color-scheme: dark) { :root { --primary-color: #CCCCCC; --background-color: #000000; --text-color: #FFFFFF; } }

Light Theme @media (prefers-color-scheme: light) { :root { --primary-color: #CCCCCC; --background-color: #FFFFFF; --text-color: #000000; } }

1
  • Using the prefers-color-scheme CSS media feature might work if your OS or browser has been set to 'Dark' mode, however doesn't work if a SharePoint site has been set to use a dark theme.
    – Matty J
    Jul 7, 2021 at 8:00

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.