Skip to content

Commit

Permalink
fix(core): do not delay dropdown focus trap deactivation (#603)
Browse files Browse the repository at this point in the history
Co-authored-by: anastasiia_glushkova <[email protected]>
  • Loading branch information
glushkova91 and anastasiia_glushkova authored Nov 14, 2024
1 parent 90a13e7 commit dcd6198
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion core/src/components/cat-dropdown/cat-dropdown.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -182,14 +182,14 @@ export class CatDropdown {
}

this.isOpen = null;
this.trap?.deactivate();
this.content.classList.remove('show');
// give CSS transition time to apply
setTimeout(() => {
this.isOpen = false;
this.content.classList.remove('show');
this.content.style.display = '';
this.trigger?.setAttribute('aria-expanded', 'false');
this.trap?.deactivate();
this.catClose.emit();
}, timeTransitionS);
}
Expand Down

0 comments on commit dcd6198

Please sign in to comment.