Skip to content

Commit ba0414e

Browse files
committed
feat(ui): force-enable dark mode and add blurred gradients
Always enable dark mode by overriding isEnabled to true in the dark-mode service to simplify theming during development. Add three layered, animated blurred gradient backgrounds to the catalog page for enhanced visual appeal. The gradients use overlapping colored circles with spin animations and blur effects for a dynamic look.
1 parent c7c3e2a commit ba0414e

File tree

2 files changed

+33
-1
lines changed

2 files changed

+33
-1
lines changed

app/services/dark-mode.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -115,7 +115,8 @@ export default class DarkModeService extends Service {
115115
* "dark route", or derived from localStorage & system preference
116116
*/
117117
get isEnabled(): boolean {
118-
return this.currentRouteSupportsDarkMode && (this.#currentRouteRequiresDarkMode || this.#isEnabledViaPreferences || this.isEnabledTemporarily);
118+
return true;
119+
// return this.currentRouteSupportsDarkMode && (this.#currentRouteRequiresDarkMode || this.#isEnabledViaPreferences || this.isEnabledTemporarily);
119120
}
120121

121122
/**

app/templates/catalog.hbs

Lines changed: 31 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -30,4 +30,35 @@
3030
<TracksPage::TrackCard @language={{language}} />
3131
{{/each}}
3232
</div>
33+
34+
<div class="fixed inset-0 flex items-stretch justify-stretch pointer-events-none">
35+
<div class="w-full relative overflow-hidden rounded-sm">
36+
{{! Left blurred gradient }}
37+
<div class="w-1/2 h-60 absolute -bottom-32 -left-1/4 opacity-50 animate-spin-slow filter blur-[100px]">
38+
<div class="relative">
39+
<div class="rounded-full h-60 w-full bg-purple-800"></div>
40+
<div class="absolute bottom-24 -left-24 rounded-full h-60 w-full bg-red-800"></div>
41+
<div class="absolute top-24 left-24 rounded-full h-60 w-full bg-purple-600"></div>
42+
</div>
43+
</div>
44+
45+
{{! Right blurred gradient }}
46+
<div class="w-1/2 h-60 absolute -bottom-40 -right-1/4 opacity-50 animate-spin-medium filter blur-[100px]">
47+
<div class="relative">
48+
<div class="rounded-full h-60 w-full bg-blue-600"></div>
49+
<div class="absolute bottom-24 -left-24 rounded-full h-60 w-full bg-blue-700"></div>
50+
<div class="absolute top-24 left-24 rounded-full h-60 w-full bg-purple-600"></div>
51+
</div>
52+
</div>
53+
{{! Center blurred gradient }}
54+
55+
<div class="w-1/2 h-60 absolute top-0 left-1/1 right-1/4 opacity-50 animate-spin-medium filter blur-[100px]">
56+
<div class="relative">
57+
<div class="rounded-full h-60 w-full bg-blue-600"></div>
58+
<div class="absolute bottom-24 -left-24 rounded-full h-60 w-full bg-purple-700"></div>
59+
<div class="absolute top-24 left-24 rounded-full h-60 w-full bg-purple-600"></div>
60+
</div>
61+
</div>
62+
</div>
63+
</div>
3364
</div>

0 commit comments

Comments
 (0)