Hello,
Welcome to Microsoft Q&A!
We can do nothing to support dark mode on WebView programmatically .
However , there is an easy way to achieve it .
Just add an @media
section to the CSS
.
@media (prefers-color-scheme: dark) {
body {
background-color: rgb(38,38,41);
color: white;
}
a:link {
color: #0096e2;
}
a:visited {
color: #9d57df;
}
}
Refer to https://stackoverflow.com/questions/57203909/how-to-use-ios-13-darkmode-for-wkwebview .
If the response is helpful, please click "Accept Answer" and upvote it.
Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.