Commit dbcf61aa authored by Pon Kattera's avatar Pon Kattera
Browse files

refined styles for nsfw

parent f6a902ea
......@@ -126,29 +126,32 @@ class PostSummary extends React.Component {
// author and category
const author_category = (<span className="vcard">
<Userpic account={p.author} listView={true} />
<Userpic account={p.author} />
<Author author={p.author} authorRepLog10={authorRepLog10} follow={false} mute={false} />
{} {tt('g.in')} <TagList post={p} single />&nbsp;&nbsp;
<a href={title_link_url} onClick={e => navigate(e, onClick, post, title_link_url)}><TimeAgoWrapper date={p.created} className="updated" /></a>
</span>);
// author and category
// New Post Summary heading
const summary_header = (
<div className="articles__summary-header">
<div className="user">
<div className="user__col user__col--left">
<a className="user__link" href={'/@' + p.author}>
<Userpic account={p.author} listView={true} />
</a>
</div>
{ !isNsfw
? <div className="user__col user__col--left">
<a className="user__link" href={'/@' + p.author}>
<Userpic account={p.author} listView={true} />
</a>
</div>
: ""
}
<div className="user__col user__col--right">
<a className="user__link" href={'/@' + p.author}>
<span className="user__name"><Author author={p.author} authorRepLog10={authorRepLog10} follow={false} mute={false} /></span>
</a>
<span className="user__name"><Author author={p.author} authorRepLog10={authorRepLog10} follow={false} mute={false} /></span>
<span className="articles__tag-link">{tt('g.in')}&nbsp;<TagList post={p} single />&nbsp;&nbsp;</span>
<a className="timestamp__link" href={title_link_url} onClick={e => navigate(e, onClick, post, title_link_url)}>
<span className="timestamp__time"><TimeAgoWrapper date={p.created} className="updated" /></span>
{full_power && <span className="articles__icon-steem" title={tt('g.powered_up_100')}><Icon name="steem" /></span>}
</a>
......@@ -193,14 +196,12 @@ class PostSummary extends React.Component {
return (
<article className={'PostSummary hentry'} itemScope itemType ="http://schema.org/blogPost">
<div className="PostSummary__nsfw-warning">
<div className="PostSummary__time_author_category_small show-for-small-only">
{author_category}
</div>
{tt('postsummary_jsx.this_post_is')} <span className="nsfw-flag">nsfw</span>.
{tt('postsummary_jsx.you_can')} <a href="#" onClick={this.onRevealNsfw}>{tt('postsummary_jsx.reveal_it')}</a> {tt('g.or') + ' '}
{summary_header}
<span className="nsfw-flag">nsfw</span>&nbsp;&nbsp;<a href="#" onClick={this.onRevealNsfw}>{tt('postsummary_jsx.reveal_it')}</a> {tt('g.or') + ' '}
{username ? <span>{tt('postsummary_jsx.adjust_your')} <Link to={`/@${username}/settings`}>{tt('postsummary_jsx.display_preferences')}</Link>.</span>
: <span><Link to="/pick_account">{tt('postsummary_jsx.create_an_account')}</Link> {tt('postsummary_jsx.to_save_your_preferences')}.</span>}
{content_footer}
{summary_footer}
</div>
</article>
)
......@@ -235,12 +236,14 @@ class PostSummary extends React.Component {
{summary_header}
<div className={'articles__content PostSummary hentry' + (thumb ? ' with-image ' : ' ') + commentClasses.join(' ')} itemScope itemType ="http://schema.org/blogPost">
<div className="articles__content-block articles__content-block--img">
<a className="articles__link" href="#">
{thumb}
</a>
</div>
{ thumb
? <div className="articles__content-block articles__content-block--img">
<a className="articles__link" href="#">
{thumb}
</a>
</div>
: ""
}
{/*
<div className="PostSummary__header show-for-small-only">
{content_title}
......
......@@ -9,8 +9,7 @@ ul.PostsList__summaries {
@include clearfix;
.PostSummary__nsfw-warning {
border: 1px solid $medium-gray;
border-radius: 0.5rem;
border: 1px solid $color-border-light;
padding: 0.75rem 2rem;
min-height: 80px;
.PostSummary__footer {
......@@ -31,7 +30,7 @@ ul.PostsList__summaries {
font-weight: normal;
font-family: Arial;
margin: 0 0.1rem;
padding: 0 0.2rem;
padding: 3px 5px;
}
}
......
......@@ -5,8 +5,7 @@ import proxifyImageUrl from 'app/utils/ProxifyUrl';
class Userpic extends Component {
static propTypes = {
account: PropTypes.string,
listView: PropTypes.bool
account: PropTypes.string
}
shouldComponentUpdate = shouldComponentUpdate(this, 'Userpic')
......
......@@ -514,6 +514,7 @@
&__content-block--img + &__content-block--text {
margin-top: 0;
margin-left: 14px;
}
&__resteem, &__content-block--text, &__metadata {
@include MQ(M) {
......@@ -758,13 +759,15 @@ a#changeLayout:focus {
&__content-block {
margin-bottom: 0;
&--img {
margin-right: 14px;
}
&--text {
margin-top: 0;
min-width: 300px;
}
}
}
&__content-block--img + &__content-block--text {
margin-left: 14px;
}
&__tags {
margin: 4px 0 0;
}
......
......@@ -38,7 +38,7 @@ class Topics extends React.Component {
if (compact) {
return <select className={cn} onChange={(e) => browserHistory.push(e.target.value)} value={currentValue}>
<option key={'*'} value={'/' + order}>{tt('g.topics')}...</option>
<option key={'*'} value={'/' + order}>{tt('g.all_tags')}</option>
{categories.map(cat => {
const link = order ? `/${order}/${cat}` : `/${cat}`;
return <option key={cat} value={link}>{cat}</option>
......
......@@ -99,6 +99,7 @@
"tag": "Tag",
"to": " to ",
"topics": "Topics",
"all_tags": "All tags",
"transfer": "Transfer ",
"trending_topics": "Trending Topics",
"type": "Type",
......@@ -472,7 +473,7 @@
"resteemed_by": "Resteemed by",
"this_post_is": "This post is",
"you_can": "You can",
"reveal_it": "reveal it",
"reveal_it": "Reveal this post",
"adjust_your": "adjust your",
"display_preferences": "display preferences",
"create_an_account": "create an account",
......
......@@ -99,6 +99,7 @@
"tag": "Tag",
"to": " to ",
"topics": "Topics",
"all_tags": "All tags",
"transfer": "Transfer ",
"trending_topics": "Trending Topics",
"type": "Type",
......@@ -190,7 +191,7 @@
"value_posts": "low value posts"
},
"read_only_mode": "Due to server maintenance we are running in read only mode. We are sorry for the inconvenience.",
"tags_and_topics": "Tags and Topics",
"tags_and_topics": "Tags",
"show_more_topics": "Show more topics",
"basic": "Basic",
"advanced": "Advanced",
......@@ -467,7 +468,7 @@
"resteemed_by": "Resteemed by",
"this_post_is": "This post is",
"you_can": "You can",
"reveal_it": "reveal it",
"reveal_it": "Reveal this post",
"adjust_your": "adjust your",
"display_preferences": "display preferences",
"create_an_account": "create an account",
......
......@@ -99,6 +99,7 @@
"tag": "Тэг",
"to": " к ",
"topics": "Топики",
"all_tags": "All tags",
"transfer": "Передать ",
"trending_topics": "Популярное",
"type": "Тип",
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment