logo

pleroma-fe

My custom branche(s) on git.pleroma.social/pleroma/pleroma-fe git clone https://hacktivis.me/git/pleroma-fe.git

mention_link.vue (1959B)


  1. <template>
  2. <span
  3. class="MentionLink"
  4. >
  5. <!-- eslint-disable vue/no-v-html -->
  6. <a
  7. v-if="!user"
  8. :href="url"
  9. class="original"
  10. target="_blank"
  11. v-html="content"
  12. /><!-- eslint-enable vue/no-v-html -->
  13. <UserPopover
  14. v-else
  15. :user-id="user.id"
  16. :disabled="!shouldShowTooltip"
  17. >
  18. <span
  19. v-if="user"
  20. class="new"
  21. :style="style"
  22. :class="classnames"
  23. >
  24. <a
  25. class="short"
  26. :class="{ '-with-tooltip': shouldShowTooltip }"
  27. :href="url"
  28. @click.prevent="onClick"
  29. >
  30. <!-- eslint-disable vue/no-v-html -->
  31. <UserAvatar
  32. v-if="shouldShowAvatar"
  33. class="mention-avatar"
  34. :user="user"
  35. /><span
  36. class="shortName"
  37. ><FAIcon
  38. v-if="useAtIcon"
  39. size="sm"
  40. icon="at"
  41. class="at"
  42. />{{ !useAtIcon ? '@' : '' }}<span
  43. class="userName"
  44. v-html="userName"
  45. /><span
  46. v-if="shouldShowFullUserName"
  47. class="serverName"
  48. :class="{ '-faded': shouldFadeDomain }"
  49. v-html="'@' + serverName"
  50. /><UnicodeDomainIndicator
  51. v-if="shouldShowFullUserName"
  52. :user="user"
  53. />
  54. </span>
  55. <span
  56. v-if="isYou && shouldShowYous"
  57. :class="{ '-you': shouldBoldenYou }"
  58. > {{ ' ' + $t('status.you') }}</span>
  59. <!-- eslint-enable vue/no-v-html -->
  60. </a><span
  61. ref="full"
  62. class="full"
  63. >
  64. <!-- eslint-disable vue/no-v-html -->
  65. @<span v-html="userName" /><span v-html="'@' + serverName" />
  66. <!-- eslint-enable vue/no-v-html -->
  67. </span>
  68. </span>
  69. </UserPopover>
  70. </span>
  71. </template>
  72. <script src="./mention_link.js" />
  73. <style lang="scss" src="./mention_link.scss" />