/* pages/news/list.wxss */
|
.container {
|
padding: 20rpx;
|
background-color: #f5f5f5;
|
min-height: 100vh;
|
}
|
|
.news-list {
|
display: flex;
|
flex-direction: column;
|
gap: 20rpx;
|
}
|
|
.news-item {
|
background: white;
|
border-radius: 16rpx;
|
overflow: hidden;
|
box-shadow: 0 2rpx 12rpx rgba(0, 0, 0, 0.1);
|
transition: all 0.3s ease;
|
}
|
|
.news-item:active {
|
transform: scale(0.98);
|
box-shadow: 0 4rpx 16rpx rgba(0, 0, 0, 0.15);
|
}
|
|
.news-card {
|
padding: 24rpx;
|
}
|
|
.news-header {
|
margin-bottom: 16rpx;
|
}
|
|
.news-title {
|
font-size: 32rpx;
|
font-weight: 600;
|
color: #333;
|
line-height: 1.4;
|
display: -webkit-box;
|
-webkit-box-orient: vertical;
|
-webkit-line-clamp: 2;
|
overflow: hidden;
|
}
|
|
.news-body {
|
margin-bottom: 16rpx;
|
}
|
|
.news-cover {
|
margin-bottom: 16rpx;
|
border-radius: 12rpx;
|
overflow: hidden;
|
height: 280rpx;
|
}
|
|
.cover-image {
|
width: 100%;
|
height: 100%;
|
object-fit: cover;
|
}
|
|
.news-summary {
|
font-size: 28rpx;
|
color: #666;
|
line-height: 1.5;
|
display: -webkit-box;
|
-webkit-box-orient: vertical;
|
-webkit-line-clamp: 3;
|
overflow: hidden;
|
}
|
|
.news-footer {
|
display: flex;
|
justify-content: space-between;
|
align-items: center;
|
padding-top: 16rpx;
|
border-top: 1rpx solid #eee;
|
}
|
|
.news-meta {
|
display: flex;
|
align-items: center;
|
gap: 12rpx;
|
}
|
|
.author {
|
font-size: 24rpx;
|
color: #999;
|
}
|
|
.separator {
|
font-size: 24rpx;
|
color: #ddd;
|
}
|
|
.time {
|
font-size: 24rpx;
|
color: #999;
|
}
|
|
.news-stats {
|
display: flex;
|
align-items: center;
|
}
|
|
.view-count {
|
font-size: 24rpx;
|
color: #999;
|
}
|
|
/* 加载状态 */
|
.loading-wrapper {
|
display: flex;
|
flex-direction: column;
|
align-items: center;
|
padding: 40rpx 0;
|
}
|
|
.loading {
|
width: 40rpx;
|
height: 40rpx;
|
border: 4rpx solid #f3f3f3;
|
border-top: 4rpx solid #007aff;
|
border-radius: 50%;
|
animation: spin 1s linear infinite;
|
margin-bottom: 20rpx;
|
}
|
|
@keyframes spin {
|
0% { transform: rotate(0deg); }
|
100% { transform: rotate(360deg); }
|
}
|
|
.loading-text {
|
font-size: 28rpx;
|
color: #999;
|
}
|
|
/* 没有更多数据 */
|
.no-more {
|
text-align: center;
|
padding: 40rpx 0;
|
}
|
|
.no-more-text {
|
font-size: 28rpx;
|
color: #999;
|
}
|
|
/* 空状态 */
|
.empty-state {
|
display: flex;
|
flex-direction: column;
|
align-items: center;
|
padding: 100rpx 40rpx;
|
}
|
|
.empty-icon {
|
font-size: 80rpx;
|
margin-bottom: 20rpx;
|
opacity: 0.5;
|
}
|
|
.empty-text {
|
font-size: 32rpx;
|
color: #666;
|
margin-bottom: 10rpx;
|
}
|
|
.empty-desc {
|
font-size: 28rpx;
|
color: #999;
|
}
|