Support.vue 2.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596
  1. <template>
  2. <SmartModal
  3. v-if="show"
  4. :title="$t('support.title')"
  5. @close="$emit('hide-modal')"
  6. >
  7. <template #body>
  8. <div class="flex flex-col space-y-2">
  9. <SmartItem
  10. icon="menu_book"
  11. :label="$t('app.documentation')"
  12. to="https://docs.hoppscotch.io"
  13. :description="$t('support.documentation')"
  14. info-icon="chevron_right"
  15. active
  16. blank
  17. @click.native="hideModal()"
  18. />
  19. <SmartItem
  20. icon="keyboard"
  21. :label="$t('app.keyboard_shortcuts')"
  22. :description="$t('support.shortcuts')"
  23. info-icon="chevron_right"
  24. active
  25. @click.native="
  26. showShortcuts()
  27. hideModal()
  28. "
  29. />
  30. <SmartItem
  31. icon="auto_awesome"
  32. :label="$t('app.whats_new')"
  33. to="https://github.com/hoppscotch/hoppscotch/blob/main/CHANGELOG.md"
  34. :description="$t('support.changelog')"
  35. info-icon="chevron_right"
  36. active
  37. blank
  38. @click.native="hideModal()"
  39. />
  40. <SmartItem
  41. icon="contact_support"
  42. :label="$t('app.chat_with_us')"
  43. :description="$t('support.chat')"
  44. info-icon="chevron_right"
  45. active
  46. @click.native="
  47. chatWithUs()
  48. hideModal()
  49. "
  50. />
  51. <SmartItem
  52. svg="discord"
  53. :label="$t('app.join_discord_community')"
  54. to="https://hoppscotch.io/discord"
  55. blank
  56. :description="$t('support.community')"
  57. info-icon="chevron_right"
  58. active
  59. @click.native="hideModal()"
  60. />
  61. <SmartItem
  62. svg="twitter"
  63. :label="$t('app.twitter')"
  64. to="https://twitter.com/hoppscotch_io"
  65. blank
  66. :description="$t('support.twitter')"
  67. info-icon="chevron_right"
  68. active
  69. @click.native="hideModal()"
  70. />
  71. </div>
  72. </template>
  73. </SmartModal>
  74. </template>
  75. <script>
  76. import { invokeAction } from "~/helpers/actions"
  77. import { showChat } from "~/helpers/support"
  78. export default {
  79. props: {
  80. show: Boolean,
  81. },
  82. methods: {
  83. chatWithUs() {
  84. showChat()
  85. },
  86. showShortcuts() {
  87. invokeAction("flyouts.keybinds.toggle")
  88. },
  89. hideModal() {
  90. this.$emit("hide-modal")
  91. },
  92. },
  93. }
  94. </script>