change link of support button
This commit is contained in:
@@ -1,15 +1,20 @@
|
||||
<template>
|
||||
<div
|
||||
v-if="config.config.name === 'garoosi'"
|
||||
v-if="showBaleSupport"
|
||||
:class="variant === 'desktop' ? 'deducate-support' : 'wrap-fix bottom-0 px-10 py-6 flex gap-2 bg-white'"
|
||||
>
|
||||
<a class="w-full" href="tel:09031265925">
|
||||
<a
|
||||
class="w-full"
|
||||
:href="supportHref"
|
||||
:target="opensSupportInNewTab ? '_blank' : undefined"
|
||||
:rel="opensSupportInNewTab ? 'noopener noreferrer' : undefined"
|
||||
>
|
||||
<BasicButton class="w-full" type="primary">تماس با پشتیبانی</BasicButton>
|
||||
</a>
|
||||
<a href="https://ble.ir/garoosigallery">
|
||||
<a :href="baleHref" target="_blank" rel="noopener noreferrer">
|
||||
<img
|
||||
src="@/assets/img/bale.png"
|
||||
alt=""
|
||||
alt="بله"
|
||||
:class="variant === 'desktop' ? 'deducate-support__bale' : 'h-10 w-10'"
|
||||
/>
|
||||
</a>
|
||||
@@ -19,7 +24,7 @@
|
||||
v-else
|
||||
:class="variant === 'desktop' ? 'deducate-support' : 'wrap-fix bottom-0 px-10 py-5 flex gap-2 bg-white'"
|
||||
>
|
||||
<a class="w-full" href="tel:09306612518">
|
||||
<a class="w-full" :href="supportHref">
|
||||
<BasicButton class="w-full" type="primary">تماس با پشتیبانی</BasicButton>
|
||||
</a>
|
||||
<a href="">
|
||||
@@ -29,7 +34,9 @@
|
||||
</template>
|
||||
|
||||
<script lang="ts" setup>
|
||||
import { computed } from 'vue'
|
||||
import BasicButton from '@/components/BasicPacks/BasicButton.vue'
|
||||
import { getProjectBaleContactLink, getProjectSupportContactLink, isBazretalaProject } from '@/utils/config'
|
||||
import { useEducatePageContext } from '../composables/useEducatePage'
|
||||
|
||||
withDefaults(
|
||||
@@ -40,4 +47,11 @@ withDefaults(
|
||||
)
|
||||
|
||||
const { config } = useEducatePageContext()
|
||||
|
||||
const showBaleSupport = computed(
|
||||
() => config.config.name === 'garoosi' || isBazretalaProject(),
|
||||
)
|
||||
const supportHref = computed(() => getProjectSupportContactLink())
|
||||
const baleHref = computed(() => getProjectBaleContactLink())
|
||||
const opensSupportInNewTab = computed(() => supportHref.value.startsWith('http'))
|
||||
</script>
|
||||
|
||||
Reference in New Issue
Block a user