mirror of
https://github.com/kingomarnajjar/flex-template-web.git
synced 2026-07-28 20:53:24 +10:00
Show custom attribute category in listing page if present
This commit is contained in:
parent
0c73dfcba4
commit
9131afd34f
2 changed files with 11 additions and 1 deletions
|
|
@ -332,7 +332,7 @@
|
|||
}
|
||||
|
||||
.separator {
|
||||
margin: 0 10px;
|
||||
margin: 0 6px;
|
||||
}
|
||||
|
||||
.contactLink {
|
||||
|
|
|
|||
|
|
@ -231,6 +231,15 @@ export class ListingPageComponent extends Component {
|
|||
title = '',
|
||||
} = currentListing.attributes;
|
||||
|
||||
const { customAttributes } = currentListing.attributes;
|
||||
const category =
|
||||
customAttributes && customAttributes.category ? (
|
||||
<span>
|
||||
{customAttributes.category}
|
||||
<span className={css.separator}>•</span>
|
||||
</span>
|
||||
) : null;
|
||||
|
||||
const topbar = <TopbarContainer />;
|
||||
|
||||
const loadingTitle = intl.formatMessage({
|
||||
|
|
@ -503,6 +512,7 @@ export class ListingPageComponent extends Component {
|
|||
<div className={css.heading}>
|
||||
<h1 className={css.title}>{title}</h1>
|
||||
<div className={css.author}>
|
||||
{category}
|
||||
<FormattedMessage id="ListingPage.hostedBy" values={{ name: hostLink }} />
|
||||
{showContactUser ? (
|
||||
<span className={css.contactWrapper}>
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue