import { useLocation } from "react-router-dom"; import { useGleanClick } from "../../../telemetry/glean-context"; import "./index.scss"; import { A11Y_MENU } from "../../../telemetry/constants"; export function A11yNav() { const gleanClick = useGleanClick(); const { pathname } = useLocation(); const showLangMenuSkiplink = pathname.includes("/docs/"); /** * Send a signal to GA when there is an interaction on one * of the access menu links. * @param {Object} event - The event object that was fired */ function sendAccessMenuItemClick(event) { const action = new URL(event.target.href).hash; gleanClick(`${A11Y_MENU}: click ${action}`); } return (
); }