diff --git a/blocks/header-nav-chain-block/chains/header-nav-chain-block/_children/search-box.jsx b/blocks/header-nav-chain-block/chains/header-nav-chain-block/_children/search-box.jsx index 992283c520..407e950d57 100644 --- a/blocks/header-nav-chain-block/chains/header-nav-chain-block/_children/search-box.jsx +++ b/blocks/header-nav-chain-block/chains/header-nav-chain-block/_children/search-box.jsx @@ -21,7 +21,7 @@ export default ({ alwaysOpen = false, placeholderText, customSearchAction = null } }, [shouldSearchOpen]); - const handleSearchBtnMousedown = (event) => { + const handleSearchBtnMouseUp = (event) => { if (!isSearchBarPending) { // if open, prevent blur event so we don't get a race condition on click vs blur if (shouldSearchOpen) { @@ -75,7 +75,7 @@ export default ({ alwaysOpen = false, placeholderText, customSearchAction = null variant="secondary-reverse" size="small" onClick={handleClick} - onMouseDown={handleSearchBtnMousedown} + onMouseUp={handleSearchBtnMouseUp} type="button" > diff --git a/blocks/header-nav-chain-block/chains/header-nav-chain-block/default.jsx b/blocks/header-nav-chain-block/chains/header-nav-chain-block/default.jsx index e11030b835..da20a33f53 100644 --- a/blocks/header-nav-chain-block/chains/header-nav-chain-block/default.jsx +++ b/blocks/header-nav-chain-block/chains/header-nav-chain-block/default.jsx @@ -19,7 +19,6 @@ export function PresentationalNav(props) { const { ariaLabelLink, children, - closeDrawer, customFields, displayLinks, horizontalLinksHierarchy, @@ -103,7 +102,6 @@ export function PresentationalNav(props) { }`} direction="vertical" justification="start" - onClick={closeDrawer} > { document.body.classList.remove("nav-open"); }; - const closeDrawer = (event) => { - const ele = event.target; - if (ele.closest(".inner-drawer-nav")) { - return; - } - closeNavigation(); - }; - const menuButtonClickAction = () => { setSectionDrawerOpen(!isSectionDrawerOpen); document.body.classList.toggle("nav-open"); @@ -283,7 +273,6 @@ const Nav = (props) => { return (