2016-11-13 16:42:56 +01:00
|
|
|
<template>
|
2018-08-28 13:42:44 +03:00
|
|
|
<div v-if="loggedIn">
|
|
|
|
<template v-if="visibility !== 'private' && visibility !== 'direct'">
|
2020-10-21 00:31:16 +03:00
|
|
|
<FAIcon
|
|
|
|
:class="classes"
|
2020-10-28 21:31:16 +02:00
|
|
|
class="RetweetButton fa-scale-110 fa-old-padding -interactive"
|
2020-10-21 00:31:16 +03:00
|
|
|
icon="retweet"
|
|
|
|
:spin="animated"
|
|
|
|
:title="$t('tool_tip.repeat')"
|
|
|
|
@click.prevent="retweet()"
|
|
|
|
/>
|
2019-09-29 22:33:15 +03:00
|
|
|
<span v-if="!mergedConfig.hidePostStats && status.repeat_num > 0">{{ status.repeat_num }}</span>
|
2018-08-28 13:42:44 +03:00
|
|
|
</template>
|
|
|
|
<template v-else>
|
2020-10-19 19:38:49 +03:00
|
|
|
<FAIcon
|
2019-07-05 10:17:44 +03:00
|
|
|
:class="classes"
|
2020-10-28 21:31:16 +02:00
|
|
|
class="RetweetButton fa-scale-110 fa-old-padding"
|
2020-10-19 19:38:49 +03:00
|
|
|
icon="lock"
|
2019-07-05 10:17:44 +03:00
|
|
|
:title="$t('timeline.no_retweet_hint')"
|
|
|
|
/>
|
2018-08-28 13:42:44 +03:00
|
|
|
</template>
|
2018-02-02 00:45:29 +02:00
|
|
|
</div>
|
2018-08-09 16:45:52 +00:00
|
|
|
<div v-else-if="!loggedIn">
|
2020-10-19 19:38:49 +03:00
|
|
|
<FAIcon
|
2019-07-05 10:17:44 +03:00
|
|
|
:class="classes"
|
2020-10-28 21:31:16 +02:00
|
|
|
class="fa-scale-110 fa-old-padding"
|
2020-10-19 19:38:49 +03:00
|
|
|
icon="retweet"
|
2019-07-05 10:17:44 +03:00
|
|
|
:title="$t('tool_tip.repeat')"
|
|
|
|
/>
|
2019-09-29 22:33:15 +03:00
|
|
|
<span v-if="!mergedConfig.hidePostStats && status.repeat_num > 0">{{ status.repeat_num }}</span>
|
2016-11-13 16:42:56 +01:00
|
|
|
</div>
|
|
|
|
</template>
|
|
|
|
|
|
|
|
<script src="./retweet_button.js" ></script>
|
|
|
|
|
2018-04-01 05:28:20 +03:00
|
|
|
<style lang="scss">
|
|
|
|
@import '../../_variables.scss';
|
2020-10-19 19:38:49 +03:00
|
|
|
|
|
|
|
.RetweetButton {
|
|
|
|
&.-interactive {
|
|
|
|
cursor: pointer;
|
|
|
|
animation-duration: 0.6s;
|
|
|
|
|
|
|
|
&:hover {
|
|
|
|
color: $fallback--cGreen;
|
|
|
|
color: var(--cGreen, $fallback--cGreen);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
&.-repeated {
|
2018-04-01 05:28:20 +03:00
|
|
|
color: $fallback--cGreen;
|
|
|
|
color: var(--cGreen, $fallback--cGreen);
|
2018-04-07 19:30:27 +03:00
|
|
|
}
|
|
|
|
}
|
2016-11-13 16:42:56 +01:00
|
|
|
</style>
|