Cusdis 美化教程:如何自定义 CSS 样式提升评论区颜值
Cusdis 默认样式不好看?用 CSS 代码打造美观评论区!
Cusdis 是一个简洁高效的评论系统,但默认样式可能不够吸引人。想要提升评论区颜值,自定义 CSS 样式是最佳选择。
以下是一个简单的示例 CSS 代码,可以让 Cusdis 更加美观:
/* 主容器 */
.cusdis {
font-family: 'Helvetica Neue', sans-serif;
font-size: 16px;
color: #333;
background-color: #f9f9f9;
border-radius: 4px;
box-shadow: 0 0 10px rgba(0, 0, 0, 0.1);
padding: 20px;
line-height: 1.5;
}
/* 标题 */
.cusdis h3 {
font-size: 1.5rem;
font-weight: bold;
margin-bottom: 20px;
}
/* 输入框 */
.cusdis input[type='text'],
.cusdis textarea {
display: block;
width: 100%;
padding: 10px;
border: none;
border-radius: 4px;
background-color: #f5f5f5;
margin-bottom: 20px;
}
/* 按钮 */
.cusdis button {
display: inline-block;
padding: 10px 20px;
background-color: #007bff;
color: #fff;
border: none;
border-radius: 4px;
cursor: pointer;
}
/* 按钮hover效果 */
.cusdis button:hover {
background-color: #006fe6;
}
/* 评论列表 */
.cusdis .comment-list {
margin-top: 20px;
}
/* 单个评论 */
.cusdis .comment {
margin-bottom: 20px;
padding-bottom: 20px;
border-bottom: 1px solid #ddd;
}
/* 评论作者 */
.cusdis .comment .author {
font-weight: bold;
margin-bottom: 5px;
}
/* 评论时间 */
.cusdis .comment .time {
font-size: 0.8rem;
color: #888;
margin-bottom: 10px;
}
/* 评论内容 */
.cusdis .comment .content {
white-space: pre-wrap;
word-wrap: break-word;
}
你可以在你的网站上引入这些 CSS 代码,从而使 Cusdis 评论更加美观。当然,你也可以根据自己的需要进行修改和定制。
原文地址: https://www.cveoy.top/t/topic/nJ4a 著作权归作者所有。请勿转载和采集!