import React from "react" import SummaryBase from "../base/summary/SummaryBase" import SummaryLeft from "../base/summary/SummaryLeft" import { faComment, faLocationArrow, faMapMarkerAlt } from "@fortawesome/free-solid-svg-icons" import SummaryText from "../base/summary/SummaryText" import SummaryRight from "../base/summary/SummaryRight" /** * A {@link SummaryBase} representing a tweet. * * @param tweet - The tweet to represent. * @param props - Additional props to pass to the summary. * @returns {JSX.Element} * @constructor */ export default function SummaryTweet({ tweet, ...props }) { let icon if(tweet["location"]) { icon = faMapMarkerAlt } else if(tweet["place"]) { icon = faLocationArrow } else { icon = faComment } return ( window.open(`https://twitter.com/${tweet["poster"]}/status/${tweet["snowflake"]}`)} /> {tweet.content} ) }