davidhellmann / tailwindcss-fluid-type

A plugin that makes the use of Fluid Type a breeze.
MIT License
345 stars 9 forks source link

Use CQ units instead of VP Units #24

Closed davidhellmann closed 3 weeks ago

davidhellmann commented 1 year ago
mattpilott commented 1 year ago

This is something im looking for now, fluid type based on container queries (im using the tailwind container queries plugin).

If you do get a build together that has this feature i can test and give feedback (i think additional classes makes sense btw)

davidhellmann commented 1 year ago

Hey @mattpilott I didn't find time until now and I think the next two weeks I'm also busy but it's on my list. I'll make sure to ping you when I've something ready. And yes, I go the additional classes way. Maybe just an option to enable them and have it in sync with the normal ones.

mattpilott commented 1 year ago

Perfect, sounds good to me!

alan-barzilay commented 1 year ago

Is there a use case for using viewport units instead of container query units since they fallback to viewport units in the absence of a container? I suggest that if you decide to support both they should be the default and the viewport units should be optin or something (great project btw!)

davidhellmann commented 3 weeks ago

The problem is that the Viewport is a single source and a consistent way to handle fluid type. Switching to container queries sounds super intelligent, but I'm unsure if that works well. Should the type react to each @container? That can be really confusing and unpredictable. It also needs another plugin as a dependency. For now, I'll close that Issue and keep things simple. Maybe it will return to my plate when TailwindCSS 4 is launched early next year.