Skip to content

Commit

Permalink
fix: theme switch alpine variable
Browse files Browse the repository at this point in the history
  • Loading branch information
lukasvinclav committed Jun 23, 2023
1 parent 4ea3146 commit af9b6b6
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions src/unfold/templates/unfold/helpers/theme_switch.html
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{% load i18n %}

<div class="relative">
<a class="block cursor-pointer hover:text-gray-700 dark:text-gray-400 dark:hover:text-gray-200" x-on:click="openTheme = !openTheme">
<div class="relative" x-data="{ openUserLinks: false, openTheme: false }">
<a class="block cursor-pointer leading-none hover:text-gray-700 dark:text-gray-400 dark:hover:text-gray-200" x-on:click="openTheme = !openTheme">
<span class="material-symbols-outlined">
<span x-text="adminTheme == 'dark' && 'dark_mode' || adminTheme == 'light' && 'light_mode' || 'computer'"></span>
</span>
Expand Down
2 changes: 1 addition & 1 deletion src/unfold/templates/unfold/helpers/userlinks.html
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{% load i18n static %}

<div class="flex items-center ml-auto">
<div class="flex flex-row group items-center leading-none relative" x-data="{ openUserLinks: false, openTheme: false }">
<div class="flex flex-row group items-center leading-none relative">
<div class="flex gap-4">
{% include "unfold/helpers/theme_switch.html" %}

Expand Down

0 comments on commit af9b6b6

Please sign in to comment.