<template>
	<view class="hlaxPage">
		<view class="hlax_bg"></view>
		<image class="hlax_bg"
			:src="toolCfg.link?.go_see?($baseUrl + 'heliaixinTool/hlax_bg2.png'):$baseUrl + 'heliaixinTool/hlax_bg3.png'"
			mode="aspectFill" />
		<image class="hlax_btn" :src="$baseUrl + 'heliaixinTool/btn_go_see1.png'" v-if="toolCfg.link?.go_see"
			@click="onTips" />
	</view>
</template>

<script setup>
	import {
		ref,
		onMounted,
		getCurrentInstance,
		computed
	} from "vue";
	import {
		usePageCfgStore
	} from "@/stores/pageCfg";
	const {
		proxy
	} = getCurrentInstance();
	const $baseUrl = proxy.$baseUrl;
	const pageCfgStore = usePageCfgStore();

	const toolCfg = computed(() =>
		pageCfgStore?.toolList.find((item) => item.title == "鹤礼爱心") || {}
	);

	onMounted(() => {})

	//点击去查看按钮提示
	const onTips = () => {
		console.log("toolCfg:::", toolCfg);
		uni.showToast({
			title: '可去' + toolCfg.value?.link?.channelName + '渠道查看',
			icon: "none"
		})
	}
</script>

<style lang="less" scoped>
	.hlax_bg {
		position: absolute;
		width: 750rpx;
		height: 1624rpx;
		top: 0rpx;
		left: 0rpx;
	}

	.hlax_btn {
		position: absolute;
		width: 465rpx;
		height: 120rpx;
		top: 1459rpx;
		left: 143rpx;
	}
</style>