This commit is contained in:
dylanmay
2025-11-27 12:17:53 +08:00
55 changed files with 5319 additions and 503 deletions

View File

@@ -12,11 +12,16 @@ import {
import MsgEvent from './msg-event.vue';
defineOptions({ name: 'Msg' });
defineOptions({ name: 'WxMsg' });
defineProps<{
item: any;
}>();
withDefaults(
defineProps<{
item?: any;
}>(),
{
item: {},
},
);
</script>
<template>

View File

@@ -7,7 +7,6 @@ import { Typography } from 'ant-design-vue';
/** 微信消息 - 音乐 */
defineOptions({ name: 'WxMusic' });
// TODO @hwantd 和 ele 的代码风格不一致例如说props
const props = withDefaults(defineProps<WxMusicProps>(), {
title: '',
@@ -17,8 +16,6 @@ const props = withDefaults(defineProps<WxMusicProps>(), {
thumbMediaUrl: '',
});
const { Link } = Typography;
const href = computed(() => props.hqMusicUrl || props.musicUrl);
defineExpose({
@@ -28,7 +25,11 @@ defineExpose({
<template>
<div>
<Link :href="href" target="_blank" class="text-success no-underline">
<Typography.Link
:href="href"
target="_blank"
class="text-success no-underline"
>
<div
class="flex items-center rounded-[5px] border border-[#e8e8e8] bg-white p-2.5 transition hover:border-black/10 hover:shadow-sm"
>
@@ -50,6 +51,6 @@ defineExpose({
</div>
</div>
</div>
</Link>
</Typography.Link>
</div>
</template>