logo

pleroma-fe

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

navigation_pins.vue (1600B)


  1. <template>
  2. <span class="NavigationPins">
  3. <router-link
  4. v-for="item in pinnedList"
  5. :key="item.name"
  6. class="button-unstyled pinned-item"
  7. active-class="toggled"
  8. :to="getRouteTo(item)"
  9. :title="item.labelRaw || $t(item.label)"
  10. >
  11. <FAIcon
  12. v-if="item.icon"
  13. fixed-width
  14. :icon="item.icon"
  15. />
  16. <span
  17. v-if="item.iconLetter && !item.iconEmoji"
  18. class="iconLetter fa-scale-110 fa-old-padding"
  19. >{{ item.iconLetter }}</span>
  20. <StillImage
  21. v-if="item.iconEmoji"
  22. class="bookmark-emoji"
  23. :src="item.iconEmojiUrl"
  24. />
  25. <div
  26. v-if="item.badgeGetter && getters[item.badgeGetter]"
  27. class="badge -dot"
  28. :class="[`-${item.badgeStyle}`]"
  29. />
  30. </router-link>
  31. </span>
  32. </template>
  33. <script src="./navigation_pins.js"></script>
  34. <style lang="scss">
  35. .NavigationPins {
  36. display: flex;
  37. flex-wrap: wrap;
  38. overflow: hidden;
  39. height: 100%;
  40. &.alert-dot-notification {
  41. background-color: var(--badgeNotification);
  42. }
  43. &.alert-dot-neutral {
  44. background-color: var(--badgeNeutral);
  45. }
  46. .pinned-item {
  47. position: relative;
  48. flex: 1 0 3em;
  49. min-width: 2em;
  50. text-align: center;
  51. overflow: visible;
  52. box-sizing: border-box;
  53. height: 100%;
  54. .bookmark-emoji {
  55. height: 100%;
  56. box-sizing: border-box;
  57. padding: 0.5em;
  58. }
  59. & .bookmark-emoji,
  60. & .svg-inline--fa,
  61. & .iconLetter {
  62. margin: 0;
  63. }
  64. &.toggled {
  65. margin-bottom: -4px;
  66. border-bottom: 4px solid;
  67. }
  68. }
  69. }
  70. </style>