Closed Lowell20 closed 7 months ago
Are you saying the CLI is not able to copy code with a prefix correctly or even with the prefix added to the classes in the hlm components the styles do not get applied correctly?
I’ve added the prefix in the hlm component and those classes did not get applied
@Lowell20 I think this might be a tailwind limitation: https://github.com/tailwindlabs/tailwindcss/discussions/6126 What you can do is copy the code from the spartan preset and just add it directly to your tailwind config: https://github.com/goetzrobin/spartan/blob/main/libs/ui/core/hlm-tailwind-preset.js
@Lowell20 I closed this issue for now as wontfix, because of the upstream limitation. If you have a different idea of working around this, e.g. support a prefix creation function or something feel free to create a separate issue/open a PR!
No worries, thanks for the update!
Which scope/s are relevant/related to the feature request?
Don't know / other
Information
This would apply to all components. Using tailwind with prefix like:
module.exports = { presets: [require('@spartan-ng/ui-core/hlm-tailwind-preset')], prefix: 'tw-', ...
Tried using in component but does not seem to work as expected:
export const buttonVariants = cva( 'tw-rounded-md', ...
Describe any alternatives/workarounds you're currently using
No response
I would be willing to submit a PR to fix this issue