hide author bio in ArticleCard (#249)
This commit is contained in:
parent
9e5b468914
commit
b6252838a1
|
@ -42,6 +42,7 @@ type Props = {
|
||||||
followers?: Author[]
|
followers?: Author[]
|
||||||
following?: Array<Author | Topic>
|
following?: Array<Author | Topic>
|
||||||
showPublicationsCounter?: boolean
|
showPublicationsCounter?: boolean
|
||||||
|
hideBio?: boolean
|
||||||
}
|
}
|
||||||
|
|
||||||
export const AuthorCard = (props: Props) => {
|
export const AuthorCard = (props: Props) => {
|
||||||
|
@ -194,7 +195,7 @@ export const AuthorCard = (props: Props) => {
|
||||||
</div>
|
</div>
|
||||||
{/*TODO: implement plurals by i18n*/}
|
{/*TODO: implement plurals by i18n*/}
|
||||||
<Show
|
<Show
|
||||||
when={props.author.bio}
|
when={props.author.bio && !props.hideBio}
|
||||||
fallback={
|
fallback={
|
||||||
props.showPublicationsCounter ? (
|
props.showPublicationsCounter ? (
|
||||||
<div class={styles.authorAbout}>{props.author.stat?.shouts} публикаций</div>
|
<div class={styles.authorAbout}>{props.author.stat?.shouts} публикаций</div>
|
||||||
|
|
|
@ -179,6 +179,7 @@ export const ArticleCard = (props: ArticleCardProps) => {
|
||||||
<AuthorCard
|
<AuthorCard
|
||||||
author={author}
|
author={author}
|
||||||
hideWriteButton={true}
|
hideWriteButton={true}
|
||||||
|
hideBio={true}
|
||||||
hideFollow={true}
|
hideFollow={true}
|
||||||
truncateBio={true}
|
truncateBio={true}
|
||||||
isFeedMode={true}
|
isFeedMode={true}
|
||||||
|
|
Loading…
Reference in New Issue
Block a user