Closed xsyann closed 9 months ago
Thanks for looking into this. I'll take a look to see what we can do about how those colors are being written.
We might have to run the css through https://github.com/csstools/postcss-plugins/tree/main/plugins/postcss-color-functional-notation - unocss recently changed to space separation notation and I'm not sure they'll support the commas
Let's see if the unocss guys answer to your question :)
In the meanwhile, indeed, postcss-color-functional-notation
works.
I just had to use the production flag and add a class prefix in the uno transformer, otherwise I had some odd classnames generated: .\36 g4h0b{margin-top:0.5rem;}
Let's do a separate issue for the funky prefix/class name so we can track that too
@xsyann PR is up for the commas fix. I'll need another repro for the strange classnames and can tackle that one.
Hi,
Thanks for the work on the Tailwind styles processing!
However, I still have issues to render tailwind styles on gmail with the UnoCSS update. The generated html seems much cleaner, but as it is still internal and not inline CSS, some of the same issues arise.
@jsxp-email/cli
Version?:Here is a simple reproduction: https://stackblitz.com/edit/jsx-email-repro-syfmkd?file=templates%2FReproduction.tsx
The generated HTML is the following:
which don't render on gmail (and even strip the "class" attribute of the
<p>
). If I simply replace.text-green{color:rgb(74 222 128 / 1);
by.text-green{color:rgb(74, 222, 128);
, it is correctly rendered.It is a simple example, the issue is also still the same with
!
or[...]
, for instance:Nonetheless, these ones are less critical as they can be avoided using
production
flag as a workaround.