flowbite-react icon indicating copy to clipboard operation
flowbite-react copied to clipboard

Carousel is broken with Tailwind 4

Open bourquep opened this issue 11 months ago • 7 comments

  • [x] I have searched the Issues to see if this bug has already been reported
  • [x] I have tested the latest version

Steps to reproduce

After upgrading from Tailwind 3 to Tailwind 4, the Carousel isn't rendering properly. Each slide is rendered on top of each other.

Here's a CodeSandbox that reproduces the issue:

https://codesandbox.io/p/devbox/y3l7vf

Current behavior

Image

bourquep avatar Apr 16 '25 12:04 bourquep

Hi, I'm facing the same issue right now, just moved from v3 to v4. Did you manage to resolve this issue yet?

syiffanoriza avatar Jun 04 '25 08:06 syiffanoriza

Hey there, did u guys follow the release changelog migration guide? also make sure to check "Breaking Changes" section too.

See here [email protected].

SutuSebastian avatar Jun 04 '25 08:06 SutuSebastian

The sandbox does not work because of #1559

SutuSebastian avatar Jun 04 '25 08:06 SutuSebastian

Hi @SutuSebastian, I was trying to use the carousel on a pure vitawind project I just made today. everything on its latest version. Taking a step back, I'm not so sure where the issue is. Is it the carousel or the vitawind starter I'm using. Best I get back to it now.

Thanks for the heads up regarding the migration guide!

syiffanoriza avatar Jun 04 '25 08:06 syiffanoriza

Using tools like vitawind is simply redundant today.

If u want to have a fresh nice configured template using flowbite-react simply run npx create-flowbite-react@latest and pick ur framework/bundler of choice

SutuSebastian avatar Jun 04 '25 09:06 SutuSebastian

thank you, I'll keep that in mind

syiffanoriza avatar Jun 04 '25 11:06 syiffanoriza

I have fixed the bug in my proyect by changing the theme. I only swapped the absolut class with the relative class. Something like this:

carousel: {
		"item": {
			"base": "relative",
		},
	}

MarcosZeaMoreno avatar Jun 16 '25 10:06 MarcosZeaMoreno