theatlantic / django-nested-admin

Django admin classes that allow for nested inlines
http://django-nested-admin.readthedocs.org/
Other
690 stars 97 forks source link

Issue with Toggling between New Themes #251

Open akshayprakash2712 opened 3 weeks ago

akshayprakash2712 commented 3 weeks ago

Hello all,

I'm encountering an issue with a custom Theme Installation in my Django project using v. 4.2.13 and Python v. 3.9.7. In the default Admin side, there is a Moon icon for toggling the Themes (i.e. b/w Light and Dark and Auto). I want to add a Grey theme as my default with a new icon. So there are total 4 icons for themes now - Grey, Light , Dark & Auto. For implementing this, I added a new icon for the Grey theme and the icon is now not visible in the Admin panel (only the default 3 are shown) and the toggling between themes is not working. Below are the screenshots of the code for installing themes with their respective icons.

Please also note my teammate has been working on Django 5.0 for making his previous project commits in Github. We wanted to test what can happen to the same functionality if team members work on different versions since we're assuming Git essentially stores all files as basic text files with version control. I am not sure if this has anything to do with my problem.

Kindly help.

  1. Screenshot 1 - The Admin panel moon icon for theme toggle Screenshot 2024-06-14 154820

2.Screenshot 2 - js file for toggle and add the icon (admin_script.js) Screenshot 2024-06-14 155126 Screenshot 2024-06-14 155139

3.Screenshot 3 - code for add new toggle icon (color_theme_toggle.html Screenshot 2024-06-14 155217

4.Screenshot 4 - Add svg file for new icon(new.svg) Screenshot 2024-06-14 160849