Closed MobtakerFanavariPayvar closed 2 years ago
Hi, color mapping works when you link it to the relative tailwind color code (such as 'primary-600'). You can find more details on how to use mappings in the docs
In your case, assuming you mapped #1E208D to 'primary-600' in tailwind config, it would look like this
// tailwind.config.js
theme: {
// define custom color
extend: {
colors: {
primary: {
600: "#1E208D",
},
},
},
// define color mapping
nightwind: {
colors: {
primary: {
600: "#ff0000",
},
},
},
},
I cannot work with individual colors nor custom colors which I have already defined in extend section of my configuration, for example:
does not convert #1E208D to the color #fff0000 in the dark mode. I don't know if I'm misunderstanding something or doing something wrong