flowbite icon indicating copy to clipboard operation
flowbite copied to clipboard

Dropdown and drawer components do not works when the table is paginated

Open alkadoHs opened this issue 2 years ago • 7 comments

I'm using data tables to enhance pagination, filtering and searching, but when the table is paginated the dropdowns and drawers of the next page stops to work and those on the first page works fine. I don't understand why this issue is happening.

alkadoHs avatar Oct 31 '23 05:10 alkadoHs

Hey @alkadoHs,

Did you make sure that the IDs of these dropdowns and modals are unique even across paginations?

Cheers, Zoltan

zoltanszogyenyi avatar Oct 31 '23 11:10 zoltanszogyenyi

Hey @alkadoHs,

Did you make sure that the IDs of these dropdowns and modals are unique even across paginations?

Cheers, Zoltan

Yes, they are unique, I'm looping through the data from the server and providing each modal and it's corresponding trigger button with unique id of the product. But it doesn't work 😔

alkadoHs avatar Oct 31 '23 12:10 alkadoHs

@alkadoHs what framework are you using?

zoltanszogyenyi avatar Oct 31 '23 12:10 zoltanszogyenyi

@alkadoHs what framework are you using?

Codeigniter, a PHP framework

alkadoHs avatar Oct 31 '23 16:10 alkadoHs

Do you have an example online somewhere? It's hard to guess why it wouldn't work.

Did you check the FlowbiteInstances object to see what's going on?

zoltanszogyenyi avatar Nov 01 '23 10:11 zoltanszogyenyi

@zoltanszogyenyi Same problem Im using laravel10 + vue3 + inertia In inertia, using <Link> insted "This component is a light wrapper around a standard anchor link that intercepts click events and prevents full page reloads" And all page opened with Link, can't use offcanva(Drawer)

Solution for inertia:

import { router } from '@inertiajs/vue3'

router.on('success', () => { initFlowbite(); })

xujiongze avatar Feb 20 '24 14:02 xujiongze

@zoltanszogyenyi

Same problem Im using laravel10 + vue3 + inertia In inertia, using insted "This component is a light wrapper around a standard anchor link that intercepts click events and prevents full page reloads" And all page opened with Link, can't use offcanva(Drawer) Solution for inertia:

import { router } from '@inertiajs/vue3'

router.on('success', () => { initFlowbite(); })

Thank you, this helped me

embarekmessai avatar Mar 28 '24 22:03 embarekmessai