import styled, { css, keyframes } from 'styled-components';
import { StyledLoader } from '../Loader/Loader.styles';
import { StyledLabel, StyledToken } from '../Token/Token.styles';
import { colors } from '../_styles/colors';
export var pulseAnimationDuration = 600;
var focusPulse = /*#__PURE__*/keyframes(["0%{box-shadow:0 0 0 0 ", ",0 0 0 0 ", ",0 0 0 0 ", ";}25%{box-shadow:0 0 0 0 ", ",0 0 0 0 ", ",0 0 0 0 ", ";}50%{box-shadow:0 0 0 1px ", ",0 0 0 3px ", ",0 0 0 2px ", ";}100%{box-shadow:0 0 0 1.5px ", ",0 0 0 3px ", ",0 0 0 6px ", ";}"], colors.blue60, colors.blue90, colors.blue94, colors.blue60, colors.blue90, colors.blue94, colors.blue60, colors.blue90, colors.blue94, colors.blue60, colors.blue90, colors.blue94);
export var StyledFilenameShortcut = /*#__PURE__*/styled.div.withConfig({
  displayName: "StyledFilenameShortcut",
  componentId: "core-12_10_0__sc-13jx4bx-0"
})(["display:flex;"]);
export var StyledFilename = /*#__PURE__*/styled.span.withConfig({
  displayName: "StyledFilename",
  componentId: "core-12_10_0__sc-13jx4bx-1"
})(["flex:1 1 auto;overflow:hidden;text-overflow:ellipsis;"]);
export var StyledExtension = /*#__PURE__*/styled.span.withConfig({
  displayName: "StyledExtension",
  componentId: "core-12_10_0__sc-13jx4bx-2"
})(["flex-shrink:0;"]);
export var StyledFileToken = /*#__PURE__*/styled.div.withConfig({
  displayName: "StyledFileToken",
  componentId: "core-12_10_0__sc-13jx4bx-3"
})(["background-color:", ";border-radius:200px;max-width:100%;outline:none;overflow:hidden;position:relative;&:focus,&.focus{box-shadow:0 0 0 2px ", ";outline:none;", "{border-color:transparent;", "}}", "{background:none;color:", ";display:flex;user-select:none;}", "{overflow:hidden;", "{border-radius:200px 0 0 200px;color:", ";padding-right:0;transition:color 0s linear,background-color 0s linear;user-select:none;", "{flex:0 0 auto;}}}", ""], colors.gray96, colors.blue40, StyledToken, function (_ref) {
  var $progressComplete = _ref.$progressComplete;
  return $progressComplete && css(["background-color:", ";"], colors.blue45);
}, StyledToken, colors.blue40, StyledLoader, StyledToken, colors.white, StyledLabel, function (_ref2) {
  var $error = _ref2.$error,
    $finalized = _ref2.$finalized,
    $progressComplete = _ref2.$progressComplete;
  if ($error) {
    return css(["background-color:", ";&:focus{background-color:", ";}", "{color:", ";}", "{display:none;}"], colors.red50, colors.red50, StyledToken, colors.white, StyledLoader);
  } else if ($finalized || $progressComplete) {
    return css(["", ";", "{opacity:0;pointer-events:none;}", "{background-color:", ";color:", ";&:hover,&:focus{background-color:", ";}}&.hover,&.focus{", "{background-color:", ";}}"], $finalized && css(["animation-delay:0;animation-duration:", "ms;animation-name:", ";animation-timing-function:ease-out;"], pulseAnimationDuration, focusPulse), StyledLoader, StyledToken, colors.blue50, colors.white, colors.blue45, StyledToken, colors.blue45);
  }
  return css([""]);
});
//# sourceMappingURL=FileToken.styles.js.map