0
0
mirror of https://github.com/naturalcrit/homebrewery.git synced 2025-12-30 13:12:40 +00:00

Add a page count to User page

This commit is contained in:
G.Ambatte
2021-07-31 17:21:25 +12:00
parent ee006b6b16
commit 42da4b4c43
3 changed files with 15 additions and 7 deletions

View File

@@ -114,13 +114,16 @@ const BrewItem = createClass({
<span title={`Last viewed: ${moment(brew.lastViewed).local().format(dateFormatString)}`}>
<i className='fas fa-eye'/> {brew.views}
</span>
<span
title={
`Created: ${brew.createdAt ? moment(brew.createdAt).local().format(dateFormatString) : 'UNKNOWN'}\n` +
`Last updated: ${brew.updatedAt ? moment(brew.updatedAt).local().format(dateFormatString) : 'UNKNOWN'}`
}>
<i className='fas fa-sync-alt' />
{moment(brew.updatedAt).fromNow()}
{brew.pageCount &&
<span>
<i className='far fa-file' /> {brew.pageCount}
</span>
}
<span>
<i className='far fa-file' /> {brew.pageCount || 1}
</span>
<span>
<i className='fas fa-sync-alt' /> {moment(brew.updatedAt).fromNow()}
</span>
{this.renderGoogleDriveIcon()}
</div>

View File

@@ -72,4 +72,7 @@
padding : 0px;
margin : -5px;
}
.spacer {
height : 25px;
}
}