import styled, { css } from 'styled-components';
import { selectors } from '@defencedigital/design-tokens';
var color = selectors.color,
  spacing = selectors.spacing,
  zIndex = selectors.zIndex;
var TOOLTIP_BORDER_THICK = 1;
var TOOLTIP_INNER = 4;
var TOOLTIP_OUTER = TOOLTIP_INNER - 4;
var TOOLTIP_OFFSET = TOOLTIP_OUTER + TOOLTIP_BORDER_THICK;
var TOOLTIP_DARK_BG = color('neutral', '700');
var TOOLTIP_DARK_BORDER = TOOLTIP_DARK_BG;
function getPositionStyles(position) {
  var styles = {
    above: css(["&::before{border-color:", " transparent;border-width:", "px ", "px 0;margin-left:-", "px;bottom:-", "px;left:50%;}&::after{border-color:", " transparent;border-width:", "px ", "px 0;margin-left:-", "px;bottom:-", "px;left:50%;}"], TOOLTIP_DARK_BORDER, TOOLTIP_INNER, TOOLTIP_INNER, TOOLTIP_OUTER, TOOLTIP_INNER, TOOLTIP_DARK_BG, TOOLTIP_INNER, TOOLTIP_INNER, TOOLTIP_OUTER, TOOLTIP_OUTER),
    right: css(["&::before{border-color:transparent ", ";border-width:", "px ", "px ", "px 0;margin-top:-", "px;left:-", "px;top:50%;}&::after{border-color:transparent ", ";border-width:", "px ", "px ", "px 0;margin-top:-", "px;left:-", "px;top:50%;}"], TOOLTIP_DARK_BORDER, TOOLTIP_OUTER, TOOLTIP_OUTER, TOOLTIP_OUTER, TOOLTIP_OUTER, TOOLTIP_OFFSET, TOOLTIP_DARK_BG, TOOLTIP_INNER, TOOLTIP_INNER, TOOLTIP_INNER, TOOLTIP_INNER, TOOLTIP_INNER),
    below: css(["&::before{border-color:", " transparent;border-width:0 ", "px ", "px;margin-left:-", "px;top:-", "px;left:50%;}&::after{border-color:", " transparent;border-width:0 ", "px ", "px;margin-left:-", "px;top:-", "px;left:50%;}"], TOOLTIP_DARK_BORDER, TOOLTIP_OUTER, TOOLTIP_OUTER, TOOLTIP_OUTER, TOOLTIP_OFFSET, TOOLTIP_DARK_BG, TOOLTIP_INNER, TOOLTIP_INNER, TOOLTIP_INNER, TOOLTIP_INNER),
    left: css(["&::before{border-color:transparent ", ";border-width:", "px 0 ", "px ", "px;margin-top:-", "px;right:-", "px;top:50%;}&::after{border-color:transparent ", ";border-width:", "px 0 ", "px ", "px;margin-top:-", "px;right:-", "px;top:50%;}"], TOOLTIP_DARK_BORDER, TOOLTIP_OUTER, TOOLTIP_OUTER, TOOLTIP_OUTER, TOOLTIP_OUTER, TOOLTIP_OFFSET, TOOLTIP_DARK_BG, TOOLTIP_INNER, TOOLTIP_INNER, TOOLTIP_INNER, TOOLTIP_INNER, TOOLTIP_INNER)
  };
  return styles[position];
}
export var StyledContent = styled.div.withConfig({
  displayName: "StyledContent",
  componentId: "sc-1nd05e7-0"
})(["z-index:", ";background:", ";color:", ";border:", " solid ", "px;border-radius:5px;padding:", " ", ";position:relative;top:auto;left:auto;height:auto;width:auto;&::before{border-style:solid;content:'';display:block;position:absolute;width:0;z-index:0;}&::after{border-style:solid;content:'';display:block;position:absolute;width:0;z-index:1;}", ""], zIndex('modal', 1), TOOLTIP_DARK_BG, color('neutral', 'white'), TOOLTIP_DARK_BORDER, TOOLTIP_BORDER_THICK, spacing('6'), spacing('8'), function (_ref) {
  var $position = _ref.$position;
  return getPositionStyles($position);
});