diff --git a/src/components/viewPost/tp-linkCard.vue b/src/components/viewPost/tp-linkCard.vue index 8fd48de5..d583916f 100644 --- a/src/components/viewPost/tp-linkCard.vue +++ b/src/components/viewPost/tp-linkCard.vue @@ -1,12 +1,18 @@ + @@ -18,20 +24,38 @@ import { parseLink, parsePost } from "@utils/linkParser.js"; import { computed, toRaw } from "vue"; import { useRouter } from "vue-router"; +/** 链接卡片组件 */ type TpLinkCard = { + /** 插入内容 */ insert: { + /** 链接卡片数据 */ link_card: { - link_type: number; - origin_url: string; - landing_url: string; - cover: string; - title: string; + /** 卡片ID */ card_id: string; + /** 卡片状态 */ card_status: number; - market_price: string; - price?: string; - button_text?: string; + /** 封面 */ + cover: string; + /** 落地URL */ + landing_url: string; + /** 落地URL类型 */ landing_url_type: number; + /** + * 链接类型 + * @example + * 1-帖子 + */ + link_type: number; + /** 原始URL */ + origin_url: string; + /** 标题 */ + title: string; + /** 市场价格 */ + market_price?: string; + /** 价格 */ + price?: string; + /** 按钮文本 */ + button_text?: string; }; }; }; @@ -65,8 +89,9 @@ async function toLink(): Promise { await openUrl(res); } -