Compare commits

...

2 Commits

Author SHA1 Message Date
w33b 1bc505057f Fix adding theme switch event listener on login page 2026-04-18 19:15:43 +02:00
w33b a78b1c41ac Remove unused code & Move files to correct folder 2026-04-18 18:42:09 +02:00
19 changed files with 22 additions and 42 deletions
+7 -2
View File
@@ -7,14 +7,19 @@ function darkModeListener() {
} }
} }
document.querySelector("input[type='checkbox']#toogleTheme").addEventListener("click", darkModeListener); document.querySelector("input[type='checkbox']#toogleTheme")?.addEventListener("click", darkModeListener);
if(localStorage.theme) { if(localStorage.theme) {
if (localStorage.theme == 'light') { if (localStorage.theme == 'light') {
if (document.querySelector("html").classList.contains('dark')) { if (document.querySelector("html").classList.contains('dark')) {
document.querySelector("html").classList.toggle("dark"); document.querySelector("html").classList.toggle("dark");
} }
document.getElementById("toogleTheme").checked = true;
const toggleThemeButton = document.getElementById("toogleTheme");
if (toggleThemeButton) {
toggleThemeButton.checked = true;
}
} }
} else { } else {
// Default Dark Theme // Default Dark Theme
+1 -1
View File
@@ -4,7 +4,7 @@
<body class="font-sans antialiased"> <body class="font-sans antialiased">
<div class="flex flex-col min-h-screen bg-gray-100 dark:bg-neutral-900"> <div class="flex flex-col min-h-screen bg-gray-100 dark:bg-neutral-900">
@include('layouts.navigation') @include('layouts.navigation')
@include('user.partials.background') @include('partials.background')
<div class="mt-[65px]"> <div class="mt-[65px]">
@include('admin.partials.sidenav') @include('admin.partials.sidenav')
<div class="pl-64"> <div class="pl-64">
@@ -1,4 +1,3 @@
<!-- BG -->
@php @php
$array = \cache()->remember('background', 300, function () { $array = \cache()->remember('background', 300, function () {
$bg = new \App\Models\SiteBackground(); $bg = new \App\Models\SiteBackground();
+1 -1
View File
@@ -6,7 +6,7 @@
</x-slot> </x-slot>
<div class="max-w-6xl mx-auto sm:px-6 lg:px-8"> <div class="max-w-6xl mx-auto sm:px-6 lg:px-8">
@include('user.partials.background') @include('partials.background')
@livewire('playlists') @livewire('playlists')
</div> </div>
</x-app-layout> </x-app-layout>
+1 -1
View File
@@ -1,6 +1,6 @@
<x-app-layout> <x-app-layout>
<div class="max-w-6xl mx-auto sm:px-6 lg:px-8"> <div class="max-w-6xl mx-auto sm:px-6 lg:px-8">
@include('user.partials.background') @include('partials.background')
@livewire('playlist-overview', ['playlist_id' => $playlist->id]) @livewire('playlist-overview', ['playlist_id' => $playlist->id])
</div> </div>
</x-app-layout> </x-app-layout>
+1 -1
View File
@@ -6,7 +6,7 @@
@include('layouts.navigation') @include('layouts.navigation')
<!-- Page Content --> <!-- Page Content -->
<main> <main>
@include('user.partials.background') @include('partials.background')
<div <div
class="relative max-w-[120rem] mx-auto sm:px-6 lg:px-8 space-y-6 pt-20 mt-[65px] flex flex-row justify-center md:justify-normal"> class="relative max-w-[120rem] mx-auto sm:px-6 lg:px-8 space-y-6 pt-20 mt-[65px] flex flex-row justify-center md:justify-normal">
<div class="grid md:grid-flow-col gap-4 xl:w-5/6 flex-row"> <div class="grid md:grid-flow-col gap-4 xl:w-5/6 flex-row">
+2 -2
View File
@@ -7,11 +7,11 @@
@include('layouts.navigation') @include('layouts.navigation')
<!-- Page Content --> <!-- Page Content -->
<main> <main>
@include('user.partials.background') @include('partials.background')
<div class="relative max-w-[120rem] mx-auto sm:px-6 lg:px-8 space-y-6 pt-20 mt-[65px] flex flex-row justify-center md:justify-normal"> <div class="relative max-w-[120rem] mx-auto sm:px-6 lg:px-8 space-y-6 pt-20 mt-[65px] flex flex-row justify-center md:justify-normal">
<div class="grid md:grid-flow-col gap-4 w-5/6 flex-row"> <div class="grid md:grid-flow-col gap-4 w-5/6 flex-row">
@include('profile.partials.sidebar') @include('profile.partials.sidebar')
@include('user.partials.info') @include('profile.partials.info')
</div> </div>
</div> </div>
</main> </main>
+1 -1
View File
@@ -6,7 +6,7 @@
@include('layouts.navigation') @include('layouts.navigation')
<!-- Page Content --> <!-- Page Content -->
<main> <main>
@include('user.partials.background') @include('partials.background')
<div class="relative max-w-[120rem] mx-auto sm:px-6 lg:px-8 space-y-6 pt-20 mt-[65px] flex flex-row justify-center md:justify-normal"> <div class="relative max-w-[120rem] mx-auto sm:px-6 lg:px-8 space-y-6 pt-20 mt-[65px] flex flex-row justify-center md:justify-normal">
<div class="flex flex-col md:flex-row"> <div class="flex flex-col md:flex-row">
@include('profile.partials.sidebar') @include('profile.partials.sidebar')
@@ -6,7 +6,7 @@
@include('layouts.navigation') @include('layouts.navigation')
<!-- Page Content --> <!-- Page Content -->
<main> <main>
@include('user.partials.background') @include('partials.background')
<div <div
class="relative max-w-[120rem] mx-auto sm:px-6 lg:px-8 space-y-6 pt-20 mt-[65px] flex flex-row justify-center md:justify-normal"> class="relative max-w-[120rem] mx-auto sm:px-6 lg:px-8 space-y-6 pt-20 mt-[65px] flex flex-row justify-center md:justify-normal">
<div class="grid md:grid-flow-col gap-4 xl:w-5/6 flex-row"> <div class="grid md:grid-flow-col gap-4 xl:w-5/6 flex-row">
@@ -1,5 +1,5 @@
<div class="flex flex-col"> <div class="flex flex-col">
@include('user.partials.profile') @include('profile.partials.profile')
<div <div
class="overflow-hidden mt-5 relative max-w-sm min-w-80 mx-auto bg-white/40 shadow-lg ring-1 ring-black/5 rounded-xl items-center gap-6 dark:bg-neutral-950/40 backdrop-blur dark:highlight-white/5"> class="overflow-hidden mt-5 relative max-w-sm min-w-80 mx-auto bg-white/40 shadow-lg ring-1 ring-black/5 rounded-xl items-center gap-6 dark:bg-neutral-950/40 backdrop-blur dark:highlight-white/5">
@@ -33,5 +33,5 @@
</div> </div>
</div> </div>
@include('user.partials.actions') @include('profile.partials.actions')
</div> </div>
+1 -1
View File
@@ -6,7 +6,7 @@
@include('layouts.navigation') @include('layouts.navigation')
<!-- Page Content --> <!-- Page Content -->
<main> <main>
@include('user.partials.background') @include('partials.background')
<div class="relative max-w-[120rem] mx-auto sm:px-6 lg:px-8 space-y-6 pt-20 mt-[65px] flex flex-row"> <div class="relative max-w-[120rem] mx-auto sm:px-6 lg:px-8 space-y-6 pt-20 mt-[65px] flex flex-row">
<div class="flex flex-col md:flex-row"> <div class="flex flex-col md:flex-row">
@include('profile.partials.sidebar') @include('profile.partials.sidebar')
+1 -1
View File
@@ -7,7 +7,7 @@
@include('layouts.navigation') @include('layouts.navigation')
<!-- Page Content --> <!-- Page Content -->
<main> <main>
@include('user.partials.background') @include('partials.background')
<div class="relative max-w-[120rem] mx-auto sm:px-6 lg:px-8 space-y-6 pt-20 mt-[65px] mb-14 flex flex-row"> <div class="relative max-w-[120rem] mx-auto sm:px-6 lg:px-8 space-y-6 pt-20 mt-[65px] mb-14 flex flex-row">
<div class="flex flex-col md:flex-row"> <div class="flex flex-col md:flex-row">
@include('profile.partials.sidebar') @include('profile.partials.sidebar')
+1 -1
View File
@@ -6,7 +6,7 @@
@include('layouts.navigation') @include('layouts.navigation')
<!-- Page Content --> <!-- Page Content -->
<main> <main>
@include('user.partials.background') @include('partials.background')
<div class="relative max-w-[120rem] mx-auto sm:px-6 lg:px-8 space-y-6 pt-20 mt-[65px] flex flex-row"> <div class="relative max-w-[120rem] mx-auto sm:px-6 lg:px-8 space-y-6 pt-20 mt-[65px] flex flex-row">
<div class="flex flex-col md:flex-row"> <div class="flex flex-col md:flex-row">
@include('profile.partials.sidebar') @include('profile.partials.sidebar')
+1 -1
View File
@@ -1,4 +1,4 @@
<x-app-layout> <x-app-layout>
@include('user.partials.background') @include('partials.background')
@livewire('downloads-search') @livewire('downloads-search')
</x-app-layout> </x-app-layout>
+1 -1
View File
@@ -7,7 +7,7 @@
@include('layouts.navigation') @include('layouts.navigation')
<!-- Page Content --> <!-- Page Content -->
<main> <main>
@include('user.partials.background') @include('partials.background')
@livewire('live-search') @livewire('live-search')
</main> </main>
@include('layouts.footer') @include('layouts.footer')
-24
View File
@@ -1,24 +0,0 @@
<!DOCTYPE html>
<html lang="{{ str_replace('_', '-', app()->getLocale()) }}" class="scroll-smooth">
@include('partials.head')
<body class="font-sans antialiased">
<div class="flex flex-col min-h-screen bg-gray-100 dark:bg-neutral-900">
@include('layouts.navigation')
<!-- Page Content -->
<main>
@include('user.partials.background')
<div class="relative max-w-[120rem] mx-auto sm:px-6 lg:px-8 space-y-6 pt-20 mt-[65px] flex flex-row justify-center">
<div class="flex flex-col">
@include('user.partials.profile')
<div class="pt-8">
@include('user.partials.info')
</div>
</div>
</div>
</main>
@include('layouts.footer')
</div>
</body>
</html>