Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

accordion prevent close (or open) of a item. #4674

Open
jcompagner opened this issue Feb 13, 2024 · 0 comments
Open

accordion prevent close (or open) of a item. #4674

jcompagner opened this issue Feb 13, 2024 · 0 comments

Comments

@jcompagner
Copy link

in the previous accordion implementation we could do:
(panelChange)="onTabChange($event)"

and because we also had: [activeIds]="getSelectedTabId()"

that means in the onTabChange we did event.preventDefault()

and then later on when we checked if the content really could be hidden (or new one shown) we updated the "selected tab" and it would show it.

But with the new implementation that state seems to be somewhere else. And i can't find a way to block or i guess i need to do everything myself (so don't use the ngbAccordionButton directive) is this true or is there another way?

jcompagner added a commit to Servoy/servoy-eclipse that referenced this issue Feb 14, 2024
"application" (esbuild) builder

fix the default accordion to use the new directives instead of tags.

The one that doesn't work yet is the preventDefault() of the tabchange
and only change the tab on a server call that says ok.
(because the tab is now always switched by the ngbAccordionButton
directive)
see:
ng-bootstrap/ng-bootstrap#4674
jcompagner added a commit to Servoy/bootstrapcomponents that referenced this issue Feb 14, 2024
"application" (esbuild) builder

update to angular 17.1.3 and fix  the accordion to use the new
directives instead of tags.

The one that doesn't work yet is the preventDefault() of the tabchange
and only change the tab on a server call that says ok.
(because the tab is now always switched by the ngbAccordionButton
directive)
see:
ng-bootstrap/ng-bootstrap#4674
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant