<template>
	<view style="height: 20rpx;"></view>
	<zzx-waterfall :list="goodsList" nameKey="name" imageKey="picurl" textKey="artistsname" gap="10"
		@item-click="handleItemClick">
	</zzx-waterfall>
</template>

<script lang="ts" setup>
	import zzxWaterfall from '@/components/zzx-waterfall/zzx-waterfall.vue';
	import { ref, onMounted } from 'vue';
	import { http } from '@/utils/http';
	const goodsList = ref([])
	onMounted(() => {
		get_lsit()
	})
	const get_lsit = () => {
		http.get('/api/wangyi/musicChart', { loading: true })
			.then(res => {
				goodsList.value = res.songs
			})
	}

	const handleItemClick = (e : any) => {
		console.log(e);
	}
</script>

<style lang="less" scoped>

</style>