function _templateObject4() {
  var data = _taggedTemplateLiteral(["\n  max-width: 700px;\n  text-align: center;\n  margin: 60px auto;\n"]);

  _templateObject4 = function _templateObject4() {
    return data;
  };

  return data;
}

function _templateObject3() {
  var data = _taggedTemplateLiteral(["\n  display: inline-block;\n"]);

  _templateObject3 = function _templateObject3() {
    return data;
  };

  return data;
}

function _templateObject2() {
  var data = _taggedTemplateLiteral(["\n  font-size: 18px;\n  text-align: center;\n  display: flex;\n  justify-content: center;\n  line-height: 40px;\n"]);

  _templateObject2 = function _templateObject2() {
    return data;
  };

  return data;
}

function _templateObject() {
  var data = _taggedTemplateLiteral(["\n  font-family: \"Merriweather\", serif;\n  font-size: 24px;\n  color: #1e62bd;\n  margin-bottom: 12px;\n"]);

  _templateObject = function _templateObject() {
    return data;
  };

  return data;
}

function _taggedTemplateLiteral(strings, raw) { if (!raw) { raw = strings.slice(0); } return Object.freeze(Object.defineProperties(strings, { raw: { value: Object.freeze(raw) } })); }

import PropTypes from "prop-types";
import { jsx, css } from "@emotion/core";
import { TwitterShareButton, TwitterIcon } from "react-share";
import { get } from "lodash";
import window from "global/window";
var quoteClass = css(_templateObject());
var attributionClass = css(_templateObject2());
var iconClass = css(_templateObject3());
var wrapperClass = css(_templateObject4());

var PullQuote = function PullQuote(_ref) {
  var quoteText = _ref.quoteText,
      quoteAttribution = _ref.quoteAttribution,
      url = _ref.url;
  return jsx("div", {
    css: wrapperClass
  }, jsx(TwitterShareButton, {
    url: url || get(window, "location.href", ""),
    title: quoteText
  }, jsx("blockquote", {
    css: quoteClass
  }, "\u201C", quoteText, "\u201D", jsx("br", null), quoteAttribution ? jsx("span", {
    css: attributionClass
  }, "\u2014 ", quoteAttribution) : null), jsx("div", {
    css: iconClass
  }, jsx(TwitterIcon, {
    size: 24,
    round: true,
    iconBgStyle: {
      fill: "#1E62BD"
    }
  }))));
};

PullQuote.displayName = "PullQuote";
PullQuote.propTypes = {
  quoteText: PropTypes.string,
  quoteAttribution: PropTypes.string,
  url: PropTypes.string
};
export default PullQuote;