function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); if (enumerableOnly) symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; }); keys.push.apply(keys, symbols); } return keys; }

function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i] != null ? arguments[i] : {}; if (i % 2) { ownKeys(source, true).forEach(function (key) { _defineProperty(target, key, source[key]); }); } else if (Object.getOwnPropertyDescriptors) { Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)); } else { ownKeys(source).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } } return target; }

function _defineProperty(obj, key, value) { if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }

/*
Copyright (c) 2018-2019 Uber Technologies, Inc.

This source code is licensed under the MIT license found in the
LICENSE file in the root directory of this source tree.
*/
import { styled } from '../styles/index.js';
export var StyledRoot = styled('nav', function (props) {
  var _props$$theme = props.$theme,
      colors = _props$$theme.colors,
      typography = _props$$theme.typography;
  return _objectSpread({}, typography.font300, {
    color: colors.foreground,
    listStyleType: 'none',
    marginTop: 0,
    marginBottom: 0,
    marginLeft: 0,
    marginRight: 0,
    paddingTop: 0,
    paddingBottom: 0,
    paddingLeft: 0,
    paddingRight: 0
  });
});
StyledRoot.displayName = "StyledRoot";
export var StyledNavItemContainer = styled('li', {});
StyledNavItemContainer.displayName = "StyledNavItemContainer";
export var StyledNavLink = styled('a', {
  color: 'inherit',
  textDecoration: 'none'
});
StyledNavLink.displayName = "StyledNavLink";
export var StyledNavItem = styled('div', function (props) {
  var _ref;

  var $active = props.$active,
      $selectable = props.$selectable,
      $level = props.$level,
      $theme = props.$theme,
      _props$$theme2 = props.$theme,
      colors = _props$$theme2.colors,
      sizing = _props$$theme2.sizing;
  return _ref = {
    backgroundColor: $active ? colors.primary : 'transparent',
    backgroundImage: $active ? "linear-gradient(0deg, rgba(255, 255, 255, 0.92), rgba(255, 255, 255, 0.92))" : null,
    boxSizing: 'border-box'
  }, _defineProperty(_ref, $theme.direction === 'rtl' ? 'borderRightWidth' : 'borderLeftWidth', '4px'), _defineProperty(_ref, $theme.direction === 'rtl' ? 'borderRightStyle' : 'borderLeftStyle', 'solid'), _defineProperty(_ref, $theme.direction === 'rtl' ? 'borderRightColor' : 'borderLeftColor', $active ? colors.primary : 'transparent'), _defineProperty(_ref, "color", $active ? colors.primary : null), _defineProperty(_ref, "cursor", $selectable ? 'pointer' : 'default'), _defineProperty(_ref, "paddingTop", sizing.scale500), _defineProperty(_ref, "paddingBottom", sizing.scale500), _defineProperty(_ref, $theme.direction === 'rtl' ? 'paddingRight' : 'paddingLeft', "calc(".concat(sizing.scale800, " * ").concat($level, ")")), _defineProperty(_ref, $theme.direction === 'rtl' ? 'paddingLeft' : 'paddingRight', sizing.scale500), _defineProperty(_ref, ':hover', {
    color: $selectable ? colors.primary : null
  }), _defineProperty(_ref, ':focus', {
    color: $selectable ? colors.primary : null
  }), _ref;
});
StyledNavItem.displayName = "StyledNavItem";
export var StyledSubNavContainer = styled('ul', {
  listStyleType: 'none',
  marginTop: 0,
  marginBottom: 0,
  marginLeft: 0,
  marginRight: 0,
  paddingTop: 0,
  paddingBottom: 0,
  paddingLeft: 0,
  paddingRight: 0
});
StyledSubNavContainer.displayName = "StyledSubNavContainer";