/** * Copyright (c) Facebook, Inc. and its affiliates. * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. */ import React from 'react'; import clsx from 'clsx'; import NavbarNavLink from '@theme/NavbarItem/NavbarNavLink'; function DefaultNavbarItemDesktop({ className, isDropdownItem = false, ...props }) { const element = ( ); if (isDropdownItem) { return
  • {element}
  • ; } return element; } function DefaultNavbarItemMobile({className, isDropdownItem, ...props}) { return (
  • ); } export default function DefaultNavbarItem({ mobile = false, position, // Need to destructure position from props so that it doesn't get passed on. ...props }) { const Comp = mobile ? DefaultNavbarItemMobile : DefaultNavbarItemDesktop; return ( ); }