Skip to content

Instantly share code, notes, and snippets.

@vansika

vansika/lala.css

Last active Oct 26, 2020
Embed
What would you like to do?
<div className="col-xs-1 text-center">
<div className="recommendation-controls">
<>
{this.handleFeedbackOnClick('Like', faThumbsUpRegular)}
<ul
className="dropdown-menu dropdown-menu-right"
aria-labelledby="recommendationControlsDropdown"
>
<RecommendationControl
icon={faAngry}
title="I never want to hear this again!"
action={(event: React.SyntheticEvent) =>
feedback === "hate"
? this.deleteFeedback(event)
: this.submitFeedback(event, "hate")
}
className={`${feedback === "hate" ? " angry" : ""}`}
/>
handleFeedbackOnClick = (text, icon) => {
return (
<button
className="btn"
id="recommendationControlsDropdown"
data-toggle="dropdown"
aria-haspopup="true"
aria-expanded="true"
background-color='white'><FontAwesomeIcon icon={icon as IconProp} /> {text}
</button>
);
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment