Closed 0x090909 closed 3 months ago
I think this is an HMR issue I think if you do a refresh it should self fix
strange because if I take out the href prop it works
Oh wait it's not underlined because your current path doesn't match the paths of any provided by href
That's the intended behavior if you make the href something like "/" it will match anything and will therefore show selected
No wait, the underline works, its the animation of underline that goes from the current selected to the new selected that does not work when href is specified
Are you using Sveltekit?
yes
It is probaly not animating because of the navigation but it depends on how you are rendering it I would need a repro to really know.
maybe works with prerendered true only
If you can create a repro I can take a look at it. Its always worked in the applications I have used it in.
Okay I recreated the case and it works, my problem then must be because Im using geist ui + shadcn, and some css properties might collide, is it possible somehow to import only the tabs from geist without importing everything else in tailwind?
No it's currently not. I don't think it's colliding I'm currently migrating to shadcn for one of my biggest projects right now and I haven't run into any issues with this. The only overrides this library has is the gray colors.
More than likely I think the project structure is incorrect and you may not have your tabs component in a layout.
If you are looking for a fully shadcn compatible option check out https://geist.shyakadavis.me/. It's not a component library but it has the same style and APIs (probably better).
Again I haven't run into any issues while using both in my projects.
Page is being reloaded and no underline animation of the selected item works