fix(news): 渲染页面样式美化

This commit is contained in:
BTMuli
2023-04-01 00:46:43 +08:00
parent 577ca367e4
commit 77bd6fe77c
2 changed files with 7 additions and 4 deletions

View File

@@ -42,6 +42,7 @@
} }
.mys-post-img { .mys-post-img {
max-width: 100%;
width: 800px; width: 800px;
height: auto; height: auto;
border-radius: 10px; border-radius: 10px;
@@ -58,7 +59,7 @@
padding: 10px; padding: 10px;
border-radius: 10px; border-radius: 10px;
display: flex; display: flex;
background: #e1e1e1; background: #faf7e8;
} }
.mys-post-link-card-cover { .mys-post-link-card-cover {
@@ -81,13 +82,15 @@
.mys-post-link-card-title { .mys-post-link-card-title {
font-size: 20px; font-size: 20px;
color: black; font-family: Genshin, serif;
color: #546d8b;
height: 150px; height: 150px;
} }
.mys-post-link-card-price { .mys-post-link-card-price {
font-size: 20px; font-size: 20px;
color: #ff667f; font-weight: bold;
color: #ff6d6d;
display: inline-block; display: inline-block;
} }

View File

@@ -381,7 +381,7 @@ function LinkCardParser(data: PostStructuredContent): HTMLDivElement {
// 创建 button // 创建 button
const button = document.createElement("a"); const button = document.createElement("a");
button.classList.add("mys-post-link-card-btn"); button.classList.add("mys-post-link-card-btn");
button.innerHTML = data.insert.link_card.button_text || "详情" + " >"; button.innerHTML = (data.insert.link_card.button_text || "详情") + " >";
const link_url = data.insert.link_card.origin_url; const link_url = data.insert.link_card.origin_url;
if (IsMysPost(link_url)) { if (IsMysPost(link_url)) {
button.href = "/post_detail/" + link_url.split("/").pop(); button.href = "/post_detail/" + link_url.split("/").pop();