Compare commits

...

2 commits

Author SHA1 Message Date
Dessalines
b96428c42a
Merge branch 'main' into navbar-mobile-fix 2023-06-20 20:09:39 -04:00
abias
2ab3885b51 Fix mobile navbar bug 2023-06-20 19:19:40 -04:00

View file

@ -35,7 +35,11 @@ interface NavbarState {
}
function handleCollapseClick(i: Navbar) {
if (i.collapseButtonRef.current?.ariaExpanded === "true") {
if (
i.collapseButtonRef.current?.attributes &&
i.collapseButtonRef.current?.attributes.getNamedItem("aria-expanded")
?.value === "true"
) {
i.collapseButtonRef.current?.click();
}
}
@ -76,12 +80,8 @@ export class Navbar extends Component<NavbarProps, NavbarState> {
document.removeEventListener("mouseup", this.handleOutsideMenuClick);
}
// TODO class active corresponding to current pages
render() {
return this.navbar();
}
// TODO class active corresponding to current page
navbar() {
const siteView = this.props.siteRes?.site_view;
const person = UserService.Instance.myUserInfo?.local_user_view.person;
return (