feat: theme switcher

This commit is contained in:
2025-04-16 22:50:15 +00:00
parent f3ee0d0068
commit 658a69a1e2
7 changed files with 67 additions and 3 deletions

View File

@ -59,3 +59,7 @@ export const hasFeature = (pkg: Package | undefined, feature: Feature) => {
export const messageSplit = (message: any) => {
return message.message?.split('\n');
};
export const shouldPreferDark = () => {
return window.matchMedia('(prefers-color-scheme: dark)').matches;
};