XF 2.3 CSS command to determine Light or Dark theme?

CZ Eddie

Active member
I need to change the header background based on whether the light or dark mode is currently in use.
Each of the two requires a different color header.

This isn't working for me:

Code:
/* Light theme - Change header background color */
[data-theme="light"] .p-header, [data-theme="light"] .p-header-inner {
    background-color: #bdad7b !important;
}

/* Dark theme - Revert to original header color */
[data-theme="dark"] .p-header, [data-theme="dark"] .p-header-inner {
    background-color: #2f2f2f !important; /* Replace with the original dark theme color if different */
}
 
 
Back
Top Bottom