api-client/packages/hoppscotch-app/components/app/Support.vue

99 lines
2.4 KiB
Vue
Raw Normal View History

2021-08-09 12:25:30 +00:00
<template>
<SmartModal
v-if="show"
:title="t('support.title')"
2021-09-20 16:03:36 +00:00
max-width="sm:max-w-md"
2021-08-09 12:25:30 +00:00
@close="$emit('hide-modal')"
>
<template #body>
2021-08-10 08:16:42 +00:00
<div class="flex flex-col space-y-2">
2021-08-09 12:25:30 +00:00
<SmartItem
2021-08-28 00:17:33 +00:00
svg="book"
:label="t('app.documentation')"
2021-08-19 17:08:50 +00:00
to="https://docs.hoppscotch.io"
:description="t('support.documentation')"
2021-08-09 12:25:30 +00:00
info-icon="chevron_right"
active
blank
@click.native="hideModal()"
/>
<SmartItem
2021-08-28 00:17:33 +00:00
svg="zap"
:label="t('app.keyboard_shortcuts')"
:description="t('support.shortcuts')"
2021-08-09 12:25:30 +00:00
info-icon="chevron_right"
active
2021-11-17 11:55:18 +00:00
@click.native="showShortcuts()"
2021-08-09 12:25:30 +00:00
/>
<SmartItem
2021-08-28 00:17:33 +00:00
svg="gift"
:label="t('app.whats_new')"
2021-08-20 09:38:54 +00:00
to="https://docs.hoppscotch.io/changelog"
:description="t('support.changelog')"
2021-08-09 12:25:30 +00:00
info-icon="chevron_right"
active
blank
@click.native="hideModal()"
/>
<SmartItem
2021-08-28 00:17:33 +00:00
svg="message-circle"
:label="t('app.chat_with_us')"
:description="t('support.chat')"
2021-08-09 12:25:30 +00:00
info-icon="chevron_right"
active
2021-11-17 11:55:18 +00:00
@click.native="chatWithUs()"
2021-08-09 12:25:30 +00:00
/>
2021-08-10 08:16:42 +00:00
<SmartItem
2021-09-03 05:57:11 +00:00
svg="brands/discord"
:label="t('app.join_discord_community')"
2021-08-10 08:16:42 +00:00
to="https://hoppscotch.io/discord"
blank
:description="t('support.community')"
2021-08-10 08:16:42 +00:00
info-icon="chevron_right"
active
@click.native="hideModal()"
/>
2021-08-09 12:25:30 +00:00
<SmartItem
2021-09-03 05:57:11 +00:00
svg="brands/twitter"
:label="t('app.twitter')"
2021-08-28 15:18:13 +00:00
to="https://hoppscotch.io/twitter"
2021-08-09 12:25:30 +00:00
blank
:description="t('support.twitter')"
2021-08-09 12:25:30 +00:00
info-icon="chevron_right"
active
@click.native="hideModal()"
/>
</div>
</template>
</SmartModal>
</template>
2021-11-17 11:55:18 +00:00
<script setup lang="ts">
2021-08-09 12:25:30 +00:00
import { invokeAction } from "~/helpers/actions"
import { showChat } from "~/helpers/support"
import { useI18n } from "~/helpers/utils/composables"
const t = useI18n()
2021-08-09 12:25:30 +00:00
2021-11-17 11:55:18 +00:00
defineProps<{
show: Boolean
}>()
const emit = defineEmits<{
(e: "hide-modal"): void
}>()
const chatWithUs = () => {
showChat()
hideModal()
}
const showShortcuts = () => {
invokeAction("flyouts.keybinds.toggle")
}
const hideModal = () => {
emit("hide-modal")
}
2021-08-09 12:25:30 +00:00
</script>