- 添加收藏锦囊功能,支持查看和删除收藏 - 实现积分系统,每日赠送5次灵感次数 - 添加静心阅读功能,阅读15秒可获得额外次数 - 实现灵感广场,展示用户分享的名字 - 添加字源溯源组件,长按汉字查看详情 - 优化空状态和结语卡片样式统一 - 添加音频控制(静音/风铃/雨落/古琴/白噪音/森林/溪流) - 优化名字生成逻辑,确保每次返回5个不重复名字 - 修复卡片翻转样式问题 - 移除首页动态提醒气泡
377 lines
5.4 KiB
Plaintext
377 lines
5.4 KiB
Plaintext
/* 灵感广场页面 - 瀑布流风格 */
|
|
|
|
.square-container {
|
|
min-height: 100vh;
|
|
background: #F5F5F0;
|
|
padding-bottom: 40rpx;
|
|
}
|
|
|
|
/* 顶部导航 */
|
|
.header {
|
|
padding: 40rpx 30rpx 20rpx;
|
|
text-align: center;
|
|
}
|
|
|
|
.title {
|
|
font-size: 40rpx;
|
|
font-weight: 600;
|
|
color: #2D2D2D;
|
|
letter-spacing: 8rpx;
|
|
}
|
|
|
|
.subtitle {
|
|
font-size: 24rpx;
|
|
color: #999;
|
|
margin-top: 8rpx;
|
|
letter-spacing: 4rpx;
|
|
}
|
|
|
|
/* 标签栏 */
|
|
.tag-bar {
|
|
padding: 20rpx 0;
|
|
white-space: nowrap;
|
|
}
|
|
|
|
.tag-list {
|
|
padding: 0 20rpx;
|
|
}
|
|
|
|
.tag {
|
|
display: inline-block;
|
|
padding: 12rpx 28rpx;
|
|
margin: 0 10rpx;
|
|
background: #fff;
|
|
border-radius: 30rpx;
|
|
font-size: 26rpx;
|
|
color: #666;
|
|
transition: all 0.3s;
|
|
}
|
|
|
|
.tag.active {
|
|
background: #2D2D2D;
|
|
color: #fff;
|
|
}
|
|
|
|
/* 排序栏 */
|
|
.sort-bar {
|
|
display: flex;
|
|
justify-content: center;
|
|
padding: 10rpx 0 20rpx;
|
|
gap: 40rpx;
|
|
}
|
|
|
|
.sort-item {
|
|
font-size: 26rpx;
|
|
color: #999;
|
|
padding: 8rpx 16rpx;
|
|
position: relative;
|
|
}
|
|
|
|
.sort-item.active {
|
|
color: #2D2D2D;
|
|
font-weight: 500;
|
|
}
|
|
|
|
.sort-item.active::after {
|
|
content: '';
|
|
position: absolute;
|
|
bottom: 0;
|
|
left: 50%;
|
|
transform: translateX(-50%);
|
|
width: 20rpx;
|
|
height: 4rpx;
|
|
background: #B22222;
|
|
border-radius: 2rpx;
|
|
}
|
|
|
|
/* 瀑布流 */
|
|
.waterfall {
|
|
display: flex;
|
|
padding: 0 20rpx;
|
|
gap: 20rpx;
|
|
}
|
|
|
|
.column {
|
|
flex: 1;
|
|
display: flex;
|
|
flex-direction: column;
|
|
gap: 20rpx;
|
|
}
|
|
|
|
/* 帖子卡片 */
|
|
.post-card {
|
|
background: #fff;
|
|
border-radius: 16rpx;
|
|
overflow: hidden;
|
|
box-shadow: 0 4rpx 20rpx rgba(0, 0, 0, 0.06);
|
|
transition: transform 0.3s;
|
|
}
|
|
|
|
.post-card:active {
|
|
transform: scale(0.98);
|
|
}
|
|
|
|
.post-image {
|
|
width: 100%;
|
|
display: block;
|
|
}
|
|
|
|
.post-image-placeholder {
|
|
width: 100%;
|
|
height: 300rpx;
|
|
background: linear-gradient(135deg, #F5F5F0 0%, #E8E8E0 100%);
|
|
display: flex;
|
|
align-items: center;
|
|
justify-content: center;
|
|
}
|
|
|
|
.placeholder-text {
|
|
font-size: 48rpx;
|
|
font-family: 'KaiTi', 'STKaiti', serif;
|
|
color: #999;
|
|
letter-spacing: 8rpx;
|
|
}
|
|
|
|
.post-info {
|
|
padding: 20rpx;
|
|
}
|
|
|
|
.post-name {
|
|
font-size: 32rpx;
|
|
font-weight: 600;
|
|
color: #2D2D2D;
|
|
margin-bottom: 8rpx;
|
|
}
|
|
|
|
.post-origin {
|
|
font-size: 22rpx;
|
|
color: #999;
|
|
line-height: 1.5;
|
|
display: -webkit-box;
|
|
-webkit-line-clamp: 2;
|
|
-webkit-box-orient: vertical;
|
|
overflow: hidden;
|
|
}
|
|
|
|
.post-footer {
|
|
display: flex;
|
|
justify-content: space-between;
|
|
align-items: center;
|
|
margin-top: 16rpx;
|
|
padding-top: 16rpx;
|
|
border-top: 1rpx solid #f0f0f0;
|
|
}
|
|
|
|
.post-keyword {
|
|
font-size: 22rpx;
|
|
color: #B22222;
|
|
}
|
|
|
|
.post-likes {
|
|
display: flex;
|
|
align-items: center;
|
|
gap: 6rpx;
|
|
}
|
|
|
|
.like-icon {
|
|
font-size: 24rpx;
|
|
color: #999;
|
|
}
|
|
|
|
.like-count {
|
|
font-size: 22rpx;
|
|
color: #999;
|
|
}
|
|
|
|
/* 同款按钮 */
|
|
.copy-btn {
|
|
margin: 0 20rpx 20rpx;
|
|
padding: 16rpx 0;
|
|
background: #F5F5F0;
|
|
border-radius: 8rpx;
|
|
text-align: center;
|
|
}
|
|
|
|
.copy-btn text {
|
|
font-size: 24rpx;
|
|
color: #666;
|
|
}
|
|
|
|
/* 加载更多 */
|
|
.load-more {
|
|
padding: 40rpx 0;
|
|
display: flex;
|
|
justify-content: center;
|
|
}
|
|
|
|
.loading-dots {
|
|
display: flex;
|
|
gap: 12rpx;
|
|
}
|
|
|
|
.dot {
|
|
width: 12rpx;
|
|
height: 12rpx;
|
|
background: #ccc;
|
|
border-radius: 50%;
|
|
animation: bounce 1.4s infinite ease-in-out both;
|
|
}
|
|
|
|
.dot:nth-child(1) { animation-delay: -0.32s; }
|
|
.dot:nth-child(2) { animation-delay: -0.16s; }
|
|
|
|
@keyframes bounce {
|
|
0%, 80%, 100% { transform: scale(0); }
|
|
40% { transform: scale(1); }
|
|
}
|
|
|
|
.no-more {
|
|
text-align: center;
|
|
padding: 40rpx 0;
|
|
color: #999;
|
|
font-size: 24rpx;
|
|
}
|
|
|
|
/* 空状态 */
|
|
.empty {
|
|
display: flex;
|
|
flex-direction: column;
|
|
align-items: center;
|
|
padding: 100rpx 0;
|
|
}
|
|
|
|
.empty-icon {
|
|
font-size: 80rpx;
|
|
color: #ccc;
|
|
margin-bottom: 20rpx;
|
|
}
|
|
|
|
.empty-text {
|
|
font-size: 26rpx;
|
|
color: #999;
|
|
}
|
|
|
|
/* 详情弹窗 */
|
|
.detail-mask {
|
|
position: fixed;
|
|
top: 0;
|
|
left: 0;
|
|
right: 0;
|
|
bottom: 0;
|
|
background: rgba(0, 0, 0, 0.8);
|
|
display: flex;
|
|
align-items: center;
|
|
justify-content: center;
|
|
opacity: 0;
|
|
visibility: hidden;
|
|
transition: all 0.3s;
|
|
z-index: 1000;
|
|
}
|
|
|
|
.detail-mask.show {
|
|
opacity: 1;
|
|
visibility: visible;
|
|
}
|
|
|
|
.detail-container {
|
|
width: 640rpx;
|
|
max-height: 80vh;
|
|
background: #fff;
|
|
border-radius: 20rpx;
|
|
overflow: hidden;
|
|
transform: scale(0.9);
|
|
transition: all 0.3s;
|
|
position: relative;
|
|
}
|
|
|
|
.detail-container.show {
|
|
transform: scale(1);
|
|
}
|
|
|
|
.detail-image {
|
|
width: 100%;
|
|
max-height: 400rpx;
|
|
object-fit: cover;
|
|
}
|
|
|
|
.detail-info {
|
|
padding: 30rpx;
|
|
}
|
|
|
|
.detail-name {
|
|
font-size: 40rpx;
|
|
font-weight: 600;
|
|
color: #2D2D2D;
|
|
text-align: center;
|
|
margin-bottom: 16rpx;
|
|
}
|
|
|
|
.detail-origin {
|
|
font-size: 24rpx;
|
|
color: #666;
|
|
line-height: 1.6;
|
|
text-align: center;
|
|
margin-bottom: 20rpx;
|
|
}
|
|
|
|
.detail-desc {
|
|
font-size: 26rpx;
|
|
color: #555;
|
|
line-height: 1.8;
|
|
text-align: justify;
|
|
}
|
|
|
|
.detail-actions {
|
|
display: flex;
|
|
justify-content: center;
|
|
gap: 40rpx;
|
|
margin-top: 30rpx;
|
|
padding-top: 30rpx;
|
|
border-top: 1rpx solid #f0f0f0;
|
|
}
|
|
|
|
.action-btn {
|
|
display: flex;
|
|
align-items: center;
|
|
gap: 8rpx;
|
|
padding: 16rpx 40rpx;
|
|
border-radius: 40rpx;
|
|
}
|
|
|
|
.action-btn.like {
|
|
background: #F5F5F0;
|
|
}
|
|
|
|
.action-btn.copy {
|
|
background: #2D2D2D;
|
|
}
|
|
|
|
.action-icon {
|
|
font-size: 28rpx;
|
|
color: #999;
|
|
}
|
|
|
|
.action-btn.copy .action-text {
|
|
color: #fff;
|
|
}
|
|
|
|
.action-text {
|
|
font-size: 26rpx;
|
|
color: #666;
|
|
}
|
|
|
|
.detail-close {
|
|
position: absolute;
|
|
top: 20rpx;
|
|
right: 20rpx;
|
|
width: 60rpx;
|
|
height: 60rpx;
|
|
background: rgba(0, 0, 0, 0.3);
|
|
border-radius: 50%;
|
|
display: flex;
|
|
align-items: center;
|
|
justify-content: center;
|
|
font-size: 36rpx;
|
|
color: #fff;
|
|
}
|