|
@@ -9,7 +9,7 @@
|
|
|
<span class="info">{{isLottaryCpd ? 'Left' : 'Instant Giveaway'}}</span>
|
|
|
</div>
|
|
|
<div class="winner-info">
|
|
|
- <component-zoom width="320" fontSize="12">
|
|
|
+ <component-zoom width="320" fontSize="12" ref="zoomCom1">
|
|
|
<span class="count">{{data.totalCount}} Winners</span>
|
|
|
<span>to Share </span>
|
|
|
<span class="prize-name">{{isMoneyRewardCpd ? data.amountValue + ' ' + data.tokenSymbol : data.customizedReward}}</span>
|
|
@@ -57,11 +57,10 @@
|
|
|
GIVEAWAY
|
|
|
</div>
|
|
|
<div class="coin">
|
|
|
- <component-zoom width="300" fontSize="56" :txt="data.amountValue || 0">
|
|
|
+ <component-zoom width="300" fontSize="56" :txt="data.amountValue || 0" ref="zoomCom">
|
|
|
<img v-if="data.currencyIconUrl" :src="data.currencyIconUrl || imgHeaderCover" />
|
|
|
<span id="preview-after-amount">{{ data.amountValue || 0 }}</span>
|
|
|
</component-zoom>
|
|
|
-
|
|
|
</div>
|
|
|
<div class="time-area" v-if="data.type == PlayType.lottery">
|
|
|
<img class="icon-clock" :src="require('@/assets/svg/icon-time.svg')" />
|
|
@@ -109,7 +108,7 @@
|
|
|
<img class="cover" v-else :src="require('@/assets/subject/img-custom-common-bg.svg')" />
|
|
|
<img class="gift" :src="require('@/assets/subject/icon-gift.gif')" />
|
|
|
<div class="prize">
|
|
|
- <component-zoom width="300" fontSize="22">
|
|
|
+ <component-zoom width="300" fontSize="22" ref="zoomCom2">
|
|
|
<img class="icon" :src="require('@/assets/subject/icon-gift-inline.svg')"/>
|
|
|
<span class="name" id="custom-name" >
|
|
|
{{data.customizedReward}}
|
|
@@ -126,7 +125,7 @@
|
|
|
<span class="info">{{isLottaryCpd ? 'Left' : 'Instant Giveaway'}}</span>
|
|
|
</div>
|
|
|
<div class="winner-info">
|
|
|
- <component-zoom width="300" fontSize="12">
|
|
|
+ <component-zoom width="300" fontSize="12" ref="zoomCom3">
|
|
|
<span class="count">{{data.totalCount}}Winners</span>
|
|
|
<span>to Share </span>
|
|
|
<span class="prize-name">{{isMoneyRewardCpd ? data.amountValue + ' ' + data.tokenSymbol : data.customizedReward}}</span>
|
|
@@ -140,12 +139,20 @@
|
|
|
</template>
|
|
|
|
|
|
<script setup>
|
|
|
-import { defineProps, defineEmits, ref, computed, onMounted } from "vue";
|
|
|
+import { defineProps, defineEmits, ref, computed, onMounted, watch } from "vue";
|
|
|
import { formatSecondsAsDaysOrTime } from "@/uilts/help";
|
|
|
import ComponentZoom from "./component-zoom.vue";
|
|
|
import { RewardType, PlayType } from "@/types";
|
|
|
|
|
|
+let zoomCom = ref('');
|
|
|
+let zoomCom1 = ref('');
|
|
|
+let zoomCom2 = ref('');
|
|
|
+let zoomCom3 = ref('');
|
|
|
const props = defineProps({
|
|
|
+ show: {
|
|
|
+ type: Boolean,
|
|
|
+ default: true
|
|
|
+ },
|
|
|
data: {
|
|
|
type: Object,
|
|
|
default: () => {
|
|
@@ -170,6 +177,19 @@ const props = defineProps({
|
|
|
},
|
|
|
});
|
|
|
|
|
|
+watch(() => props.show, (newVal) => {
|
|
|
+ if(newVal) {
|
|
|
+ zoomCom.value && zoomCom.value.setFontZoom(0);
|
|
|
+ zoomCom1.value && zoomCom.value.setFontZoom(0);
|
|
|
+ zoomCom2.value && zoomCom.value.setFontZoom(0);
|
|
|
+ zoomCom3.value && zoomCom.value.setFontZoom(0);
|
|
|
+ }
|
|
|
+ },
|
|
|
+ {
|
|
|
+ deep: true
|
|
|
+ })
|
|
|
+
|
|
|
+
|
|
|
|
|
|
let isMoneyRewardCpd =computed(() => {
|
|
|
return props.data.rewardType === RewardType.money
|