feat: 🚀 😃 convert repo into a monorepo 🚀 😃 (#51)

* Merge main into turbo-monrepo

* feat: rename apps

* feat: remove supbase videos and serve all from project

* feat: move supabase to root

* feat: update README

* docs: update link
This commit is contained in:
Rotimi Best
2023-11-25 21:56:02 +00:00
committed by GitHub
parent 03ca379094
commit 41e29014ef
806 changed files with 85853 additions and 5746 deletions
@@ -0,0 +1,14 @@
export function setTheme(theme: string) {
// In case the default theme is added but another theme exists
if (!theme && document.body.className.includes('theme-')) {
const regex = /theme-[\w]+/gi;
document.body.className = document.body.className.replace(regex, theme);
return;
}
// In case theme already exists in dom, don't add
if (document.body.className.includes(theme)) return;
localStorage.setItem('theme', theme);
document.body.className = document.body.className.concat(' ', theme);
}