[tailwind] an option to export all Class Styles (panel Class Styles) into a custom style sheet

Hi,
With Tailwindcss addon enabled, we have an extra feature called Class Styles, that enable us to create custom classes that group together native tailwindcss classes.
It’s tied to the IDE and we can’t reuse them in an other project, that’s unfortunate.
In the end, you implemented the Tailwindcss feature natively in the IDE (which is great) :
.btn {
@apply px-4 py-2 bg-blue-600 text-white rounded;
}
But without the ability to save the result into a custom css file.

From this panel, we should have the option to export all defined Class Styles into a css file of our choice (the same way that we can export inline styles from Style panel into the CSS file of our choice). The complexity of what I ask is that when its done, all Class Style attached on DOM elements should be removed and replaced by their CSS class name counterpart coming from the css file where css rules have been saved, and this is a problem because you give liberties to how we name the Class Styles that don’t comply to CSS Class Name restrictions.
But I would gladly accept an automatic reformat of the Class Styles Name to be operationnal CSS Class Name.

As shown on the below screenshot, the option to export should be in the pointed menu
image

Thanks!

4 Likes