Hello,
I’ve started using dmc for my dashboard, but i seem to have issue with just the example provided for theme switching. I’ve found when using this code for my switch:
layout = dmc.Switch(
offLabel=DashIconify(icon=“radix-icons:moon”, width=20),
onLabel=DashIconify(icon=“radix-icons:sun”, width=20),
size=“xl”,
)
The switch correctly renders, but when i activate the switch from moon to sun and back, the original moon icon is replaced with the sun icon:
1 (not yet switched):
2 (switched to on):
3 (returned to off):
Is there something I’m not understanding with this simple example? Thanks in advance!