react-icons/bi#BiCommentDetail JavaScript Examples
The following examples show how to use
react-icons/bi#BiCommentDetail.
You can vote up the ones you like or vote down the ones you don't like,
and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example #1
Source File: DevToCard.js From hackertab.dev with Apache License 2.0 | 5 votes |
ArticleItem = ({ item, index, analyticsTag }) => {
const { listingMode } = useContext(PreferencesContext)
return (
<CardItemWithActions
source={'devto'}
index={index}
key={index}
item={item}
cardItem={
<>
<CardLink link={item.url} analyticsSource={analyticsTag}>
{listingMode === 'compact' && (
<div className="counterWrapper">
<AiOutlineLike />
<span className="value">{item.public_reactions_count}</span>
</div>
)}
<div className="subTitle">{item.title}</div>
</CardLink>
{listingMode === 'normal' && (
<>
<p className="rowDescription">
<span className="rowItem">
<MdAccessTime className={'rowTitleIcon'} />
{format(new Date(item.published_at))}
</span>
<span className="rowItem">
<BiCommentDetail className={'rowTitleIcon'} />
{item.comments_count} comments
</span>
<span className="rowItem">
<AiOutlineLike className={'rowTitleIcon'} />
{item.public_reactions_count} reactions
</span>
</p>
<p className="rowDetails">
<ColoredLanguagesBadge languages={item.tag_list} />
</p>
</>
)}
</>
}
/>
)
}
Example #2
Source File: HNCard.js From hackertab.dev with Apache License 2.0 | 5 votes |
StoryItem = ({ item, index, analyticsTag }) => {
const { listingMode } = useContext(PreferencesContext)
return (
<CardItemWithActions
source={'hackernews'}
index={index}
item={item}
key={index}
cardItem={
<>
<p className="rowTitle">
<CardLink link={item.url} analyticsSource={analyticsTag}>
{listingMode === 'compact' && (
<span className="counterWrapper">
<VscTriangleUp />
<span className="value">{item.score}</span>
</span>
)}
<span className="subTitle">{item.title}</span>
</CardLink>
</p>
{listingMode === 'normal' && (
<div className="rowDetails">
<span className="rowItem hnRowItem">
<GoPrimitiveDot className="rowItemIcon" /> {item.score} points
</span>
<span className="rowItem" title={new Date(item.time * 1000).toUTCString()}>
<MdAccessTime className="rowItemIcon" /> {format(new Date(item.time * 1000))}
</span>
<ClickableItem
link={`https://news.ycombinator.com/item?id=${item.id}`}
className="rowItem rowItemClickable"
analyticsSource={analyticsTag}>
<BiCommentDetail className="rowItemIcon" /> {item.descendants} comments
</ClickableItem>
</div>
)}
</>
}
/>
)
}
Example #3
Source File: HashNodeCard.js From hackertab.dev with Apache License 2.0 | 5 votes |
ArticleItem = ({ item, index, analyticsTag }) => {
const { listingMode } = useContext(PreferencesContext)
return (
<CardItemWithActions
source={'hashnode'}
index={index}
key={index}
item={{ ...item, url: item.link }}
cardItem={
<>
<CardLink link={item.link} analyticsSource={analyticsTag}>
{listingMode === 'compact' && (
<div className="counterWrapper">
<AiTwotoneHeart />
<span className="value">{item.totalReactions || 0}</span>
</div>
)}
<div className="subTitle">{item.title}</div>
</CardLink>
{listingMode === 'normal' && (
<>
<p className="rowDescription">
<span className="rowItem">
<MdAccessTime className={'rowTitleIcon'} />
{format(new Date(item.dateAdded))}
</span>
<span className="rowItem">
<BiCommentDetail className={'rowTitleIcon'} />
{item.replyCount || 0} comments
</span>
<span className="rowItem">
<AiTwotoneHeart className={'rowTitleIcon'} />
{item.totalReactions || 0} reactions
</span>
</p>
<p className="rowDetails">
<ColoredLanguagesBadge languages={item.tag_list} />
</p>
</>
)}
</>
}
/>
)
}
Example #4
Source File: LobstersCard.js From hackertab.dev with Apache License 2.0 | 5 votes |
StoryItem = ({ item, index, analyticsTag }) => {
const { listingMode } = useContext(PreferencesContext)
return (
<CardItemWithActions
source={'lobsters'}
index={index}
item={item}
key={index}
cardItem={
<>
<p className="rowTitle">
<CardLink link={item.url} analyticsSource={analyticsTag}>
{listingMode === 'compact' && (
<div className="counterWrapper">
<VscTriangleUp />
<span className="value">{item.score}</span>
</div>
)}
<div className="subTitle">{item.title}</div>
</CardLink>
</p>
{listingMode === 'normal' && (
<div className="rowDetails">
<span className="rowItem lobstersRowItem">
<GoPrimitiveDot className="rowItemIcon" /> {item.score} points
</span>
<span className="rowItem" title={new Date(item.created_at).toUTCString()}>
<MdAccessTime className="rowItemIcon" /> {format(new Date(item.created_at))}
</span>
<ClickableItem
link={item.comments_url}
className="rowItem rowItemClickable"
analyticsSource={analyticsTag}>
<BiCommentDetail className="rowItemIcon" /> {item.comment_count} comments
</ClickableItem>
</div>
)}
</>
}
/>
)
}
Example #5
Source File: ProductHuntCard.js From hackertab.dev with Apache License 2.0 | 5 votes |
ProductItem = ({ item, index, analyticsTag }) => {
const { listingMode } = useContext(PreferencesContext)
return (
<CardItemWithActions
source={'producthunt'}
index={index}
key={index}
item={{ ...item, title: item.name }}
cardItem={(
<div className="phItem">
<img className="phImage" src={item.thumbnail.url} />
<div className="phContent">
<CardLink link={item.url} appendRef={false} analyticsSource={analyticsTag}>
{item.name}
</CardLink>
<p className="rowDescription">{item.tagline}</p>
{listingMode === "normal" &&
<p className="rowDetails">
<span className="rowItem"><BiCommentDetail className="rowItemIcon" /> {item.commentsCount || 0} comments</span>
{
item.topics && item.topics.lenght > 0 ?
<span className="rowItem">{item.topics[0]}</span> :
null
}
</p>
}
</div>
<div className="phVote">
<VscTriangleUp className="rowItemIcon" />
<span className="phVotesCount">{item.votesCount}</span>
</div>
</div>
)}
/>
)
}
Example #6
Source File: RedditCard.js From hackertab.dev with Apache License 2.0 | 5 votes |
PostItem = ({ item, index, analyticsTag }) => {
const fullUrl = `https://www.reddit.com${item.permalink}`
const { listingMode } = useContext(PreferencesContext)
return (
<CardItemWithActions
source={"reddit"}
index={index}
key={index}
item={{ ...item, url: fullUrl }}
cardItem={
<>
<CardLink link={fullUrl} analyticsSource={analyticsTag}>
{ listingMode === "compact" &&
<div className="counterWrapper">
<VscTriangleUp/>
<span className="value">{item.score}</span>
</div>
}
<div className="subTitle">
{item.link_flair_text && <PostFlair {...item} />}
{item.title}
</div>
</CardLink>
<div className="rowDetails">
{listingMode === "normal" && (
<>
<span className="rowItem redditRowItem">
<GoPrimitiveDot className="rowItemIcon" /> {item.score}{" "}
points
</span>
<span className="rowItem">
<MdAccessTime className="rowItemIcon" />{" "}
{format(new Date(item.created_utc * 1000))}
</span>
<span className="rowItem">
<BiCommentDetail className="rowItemIcon" />{" "}
{item.num_comments} comments
</span>
<span className="rowItem">
<BsArrowReturnRight className="rowItemIcon" />{" "}
{`r/${item.subreddit}`}
</span>
</>
) }
</div>
</>
}
/>
);
}