mirror of
https://github.com/Ocelot-Social-Community/Ocelot-Social.git
synced 2025-12-13 07:46:06 +00:00
added date to the author component
This commit is contained in:
parent
e814225934
commit
7bab09449d
@ -11,10 +11,21 @@
|
|||||||
:href="author.slug ? $router.resolve({ name: 'profile-slug', params: { slug: author.slug } }).href : null"
|
:href="author.slug ? $router.resolve({ name: 'profile-slug', params: { slug: author.slug } }).href : null"
|
||||||
@mouseover="popoverMouseEnter"
|
@mouseover="popoverMouseEnter"
|
||||||
@mouseleave="popoveMouseLeave">
|
@mouseleave="popoveMouseLeave">
|
||||||
|
<div style="display: inline-block;">
|
||||||
<ds-avatar
|
<ds-avatar
|
||||||
:image="author.avatar"
|
:image="author.avatar"
|
||||||
:name="author.name"
|
:name="author.name"
|
||||||
size="32px" /> <b class="username">{{ author.name | truncate(trunc) }}</b>
|
style="display: inline-block;"
|
||||||
|
size="32px" />
|
||||||
|
</div>
|
||||||
|
<div style="display: inline-block; padding-top: 20px;">
|
||||||
|
<b class="username">{{ author.name | truncate(trunc) }}</b><br>
|
||||||
|
<ds-text
|
||||||
|
size="small"
|
||||||
|
color="soft">
|
||||||
|
{{ post.createdAt | date }}
|
||||||
|
</ds-text>
|
||||||
|
</div>
|
||||||
</a>
|
</a>
|
||||||
<div
|
<div
|
||||||
slot="popover"
|
slot="popover"
|
||||||
@ -26,35 +37,32 @@
|
|||||||
:name="author.name || 'Anonymus'"
|
:name="author.name || 'Anonymus'"
|
||||||
class="profile-avatar"
|
class="profile-avatar"
|
||||||
size="90px" />-->
|
size="90px" />-->
|
||||||
|
<hc-badges
|
||||||
|
v-if="author.badges && author.badges.length"
|
||||||
|
:badges="author.badges"
|
||||||
|
size="small"
|
||||||
|
style="padding-top: 5px; margin-bottom: -15px" />
|
||||||
<ds-flex>
|
<ds-flex>
|
||||||
<ds-flex-item class="ds-tab-nav-item">
|
<ds-flex-item class="ds-tab-nav-item">
|
||||||
<ds-space margin="small">
|
<ds-space margin="small">
|
||||||
<ds-text
|
<ds-number
|
||||||
size="x-large"
|
:count="fanCount"
|
||||||
style="margin-bottom: 0; text-align: center">{{ fanCount }}</ds-text>
|
label="Fans"
|
||||||
<ds-text
|
size="x-large" />
|
||||||
size="small"
|
|
||||||
style="text-align: center">Fans</ds-text>
|
|
||||||
</ds-space>
|
</ds-space>
|
||||||
</ds-flex-item>
|
</ds-flex-item>
|
||||||
<ds-flex-item class="ds-tab-nav-item ds-tab-nav-item-active">
|
<ds-flex-item class="ds-tab-nav-item ds-tab-nav-item-active">
|
||||||
<ds-space margin="small">
|
<ds-space margin="small">
|
||||||
<ds-text
|
<ds-number
|
||||||
size="x-large"
|
:count="author.contributionsCount"
|
||||||
style="margin-bottom: 0; text-align: center">{{ author.contributionsCount || 0 }}</ds-text>
|
label="Beiträge" />
|
||||||
<ds-text
|
|
||||||
size="small"
|
|
||||||
style="text-align: center">Beiträge</ds-text>
|
|
||||||
</ds-space>
|
</ds-space>
|
||||||
</ds-flex-item>
|
</ds-flex-item>
|
||||||
<ds-flex-item class="ds-tab-nav-item">
|
<ds-flex-item class="ds-tab-nav-item">
|
||||||
<ds-space margin="small">
|
<ds-space margin="small">
|
||||||
<ds-text
|
<ds-number
|
||||||
size="x-large"
|
:count="author.commentsCount"
|
||||||
style="margin-bottom: 0; text-align: center">{{ author.commentsCount || 0 }}</ds-text>
|
label="Kommentare" />
|
||||||
<ds-text
|
|
||||||
size="small"
|
|
||||||
style="text-align: center">Kommentare</ds-text>
|
|
||||||
</ds-space>
|
</ds-space>
|
||||||
</ds-flex-item>
|
</ds-flex-item>
|
||||||
</ds-flex>
|
</ds-flex>
|
||||||
@ -85,6 +93,8 @@
|
|||||||
|
|
||||||
<script>
|
<script>
|
||||||
import HcFollowButton from '~/components/FollowButton.vue'
|
import HcFollowButton from '~/components/FollowButton.vue'
|
||||||
|
import HcCountTo from '~/components/CountTo.vue'
|
||||||
|
import HcBadges from '~/components/Badges.vue'
|
||||||
|
|
||||||
let mouseEnterTimer = null
|
let mouseEnterTimer = null
|
||||||
let mouseLeaveTimer = null
|
let mouseLeaveTimer = null
|
||||||
@ -92,7 +102,9 @@ let mouseLeaveTimer = null
|
|||||||
export default {
|
export default {
|
||||||
name: 'HcAuthor',
|
name: 'HcAuthor',
|
||||||
components: {
|
components: {
|
||||||
HcFollowButton
|
HcFollowButton,
|
||||||
|
HcCountTo,
|
||||||
|
HcBadges
|
||||||
},
|
},
|
||||||
props: {
|
props: {
|
||||||
post: { type: Object, default: null },
|
post: { type: Object, default: null },
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user