Harden weapp for review: silent audit book, no flashy module defaults, safe-area PX, subpackages/lazyCodeLoading, and CDN nav icons. Document pre3 and move next work to pre4. Co-authored-by: Cursor <cursoragent@cursor.com>
386 lines
6.9 KiB
SCSS
386 lines
6.9 KiB
SCSS
/* 真实 px:weapp pxExclude — 知识帖阅读页 */
|
||
.zd {
|
||
min-height: 100vh;
|
||
background: #0c0c0f;
|
||
color: #e8eef7;
|
||
padding-bottom: 80px;
|
||
box-sizing: border-box;
|
||
font-family: -apple-system, BlinkMacSystemFont, 'PingFang SC', 'Helvetica Neue',
|
||
'Noto Sans SC', 'Microsoft YaHei', sans-serif;
|
||
}
|
||
.zd-loading {
|
||
display: block;
|
||
text-align: center;
|
||
padding: 64px 16px;
|
||
color: #94a3b8;
|
||
font-size: 14px;
|
||
}
|
||
.zd-boot {
|
||
display: flex;
|
||
align-items: center;
|
||
justify-content: center;
|
||
padding: 80px 16px;
|
||
}
|
||
.zd-nav-trail {
|
||
width: 44px;
|
||
height: 44px;
|
||
display: flex;
|
||
align-items: center;
|
||
justify-content: center;
|
||
}
|
||
.zd-spin {
|
||
width: 36px;
|
||
height: 36px;
|
||
}
|
||
.zd-spin-sm {
|
||
width: 18px;
|
||
height: 18px;
|
||
}
|
||
.zd-spin-ring {
|
||
width: 100%;
|
||
height: 100%;
|
||
border-radius: 50%;
|
||
border: 2px solid rgba(245, 158, 11, 0.2);
|
||
border-top-color: #f59e0b;
|
||
animation: zd-spin 0.7s linear infinite;
|
||
}
|
||
.zd-spin-sm .zd-spin-ring {
|
||
border-width: 1.5px;
|
||
}
|
||
@keyframes zd-spin {
|
||
to {
|
||
transform: rotate(360deg);
|
||
}
|
||
}
|
||
.zd-nav {
|
||
display: flex;
|
||
align-items: center;
|
||
min-height: 44px;
|
||
height: 44px;
|
||
padding-left: 4px;
|
||
box-sizing: border-box;
|
||
border-bottom: 1px solid rgba(255, 255, 255, 0.06);
|
||
}
|
||
.zd-back {
|
||
width: 44px;
|
||
height: 44px;
|
||
display: flex;
|
||
align-items: center;
|
||
justify-content: center;
|
||
color: #f59e0b;
|
||
font-size: 18px;
|
||
}
|
||
.zd-nav-title {
|
||
flex: 1;
|
||
text-align: center;
|
||
font-size: 15px;
|
||
font-weight: 600;
|
||
color: #94a3b8;
|
||
}
|
||
.zd-article {
|
||
padding: 18px 18px 8px;
|
||
}
|
||
.zd-badges {
|
||
display: flex;
|
||
gap: 6px;
|
||
margin-bottom: 10px;
|
||
}
|
||
.zd-badge {
|
||
font-size: 10px;
|
||
font-weight: 700;
|
||
padding: 2px 6px;
|
||
border-radius: 4px;
|
||
}
|
||
.zd-badge.pin {
|
||
background: rgba(245, 158, 11, 0.2);
|
||
color: #fbbf24;
|
||
}
|
||
.zd-badge.feat {
|
||
background: rgba(94, 234, 212, 0.15);
|
||
color: #5eead4;
|
||
}
|
||
.zd-badge.trial {
|
||
background: rgba(96, 165, 250, 0.18);
|
||
color: #93c5fd;
|
||
}
|
||
.zd-badge.trial {
|
||
background: rgba(96, 165, 250, 0.18);
|
||
color: #93c5fd;
|
||
}
|
||
.zd-lock {
|
||
margin: 8px 0 20px;
|
||
padding: 16px 14px 18px;
|
||
border-radius: 14px;
|
||
background: linear-gradient(160deg, rgba(245, 158, 11, 0.12), rgba(15, 23, 42, 0.55));
|
||
border: 1px solid rgba(245, 158, 11, 0.28);
|
||
text-align: center;
|
||
}
|
||
.zd-lock-excerpt {
|
||
display: block;
|
||
font-size: 14px;
|
||
color: #cbd5e1;
|
||
line-height: 1.65;
|
||
text-align: left;
|
||
margin-bottom: 12px;
|
||
}
|
||
.zd-lock-ghost {
|
||
position: relative;
|
||
margin-bottom: 14px;
|
||
padding: 10px 0 4px;
|
||
overflow: hidden;
|
||
border-radius: 8px;
|
||
}
|
||
.zd-lock-line {
|
||
height: 10px;
|
||
border-radius: 5px;
|
||
margin: 0 0 8px;
|
||
background: linear-gradient(
|
||
90deg,
|
||
rgba(255, 255, 255, 0.06),
|
||
rgba(245, 158, 11, 0.14),
|
||
rgba(255, 255, 255, 0.06)
|
||
);
|
||
background-size: 200% 100%;
|
||
animation: zd-shimmer 1.8s ease-in-out infinite;
|
||
filter: blur(2.5px);
|
||
}
|
||
.zd-lock-line.w95 {
|
||
width: 95%;
|
||
}
|
||
.zd-lock-line.w88 {
|
||
width: 88%;
|
||
}
|
||
.zd-lock-line.w72 {
|
||
width: 72%;
|
||
}
|
||
.zd-lock-line.w90 {
|
||
width: 90%;
|
||
}
|
||
.zd-lock-line.w60 {
|
||
width: 60%;
|
||
}
|
||
@keyframes zd-shimmer {
|
||
0% {
|
||
background-position: 100% 0;
|
||
}
|
||
100% {
|
||
background-position: -100% 0;
|
||
}
|
||
}
|
||
.zd-lock-mosaic {
|
||
position: absolute;
|
||
inset: 0;
|
||
background:
|
||
repeating-linear-gradient(
|
||
-28deg,
|
||
rgba(12, 12, 15, 0.12) 0 3px,
|
||
rgba(245, 158, 11, 0.05) 3px 6px
|
||
),
|
||
linear-gradient(180deg, transparent, rgba(12, 12, 15, 0.75));
|
||
}
|
||
.zd-lock-title {
|
||
display: block;
|
||
font-size: 17px;
|
||
font-weight: 800;
|
||
color: #fbbf24;
|
||
margin-bottom: 6px;
|
||
}
|
||
.zd-lock-desc {
|
||
display: block;
|
||
font-size: 13px;
|
||
color: #94a3b8;
|
||
margin-bottom: 14px;
|
||
line-height: 1.4;
|
||
}
|
||
.zd-lock-btn {
|
||
display: inline-flex;
|
||
align-items: center;
|
||
justify-content: center;
|
||
min-height: 44px;
|
||
padding: 0 22px;
|
||
border-radius: 12px;
|
||
background: #f59e0b;
|
||
color: #0c0c0f;
|
||
font-weight: 800;
|
||
font-size: 15px;
|
||
}
|
||
.zd-bar-unlock {
|
||
flex: 1;
|
||
min-height: 40px;
|
||
border-radius: 10px;
|
||
background: rgba(245, 158, 11, 0.18);
|
||
border: 1px solid rgba(245, 158, 11, 0.4);
|
||
color: #fbbf24;
|
||
font-size: 13px;
|
||
font-weight: 700;
|
||
display: flex;
|
||
align-items: center;
|
||
justify-content: center;
|
||
}
|
||
.zd-title {
|
||
display: block;
|
||
font-size: 24px;
|
||
font-weight: 800;
|
||
line-height: 1.35;
|
||
letter-spacing: -0.02em;
|
||
margin-bottom: 14px;
|
||
}
|
||
.zd-byline {
|
||
display: flex;
|
||
align-items: center;
|
||
gap: 10px;
|
||
margin-bottom: 20px;
|
||
padding-bottom: 16px;
|
||
border-bottom: 1px solid rgba(255, 255, 255, 0.06);
|
||
}
|
||
.zd-avatar {
|
||
width: 40px;
|
||
height: 40px;
|
||
border-radius: 50%;
|
||
background: linear-gradient(135deg, #f59e0b, #b45309);
|
||
display: flex;
|
||
align-items: center;
|
||
justify-content: center;
|
||
font-size: 15px;
|
||
font-weight: 700;
|
||
color: #0c0c0f;
|
||
flex-shrink: 0;
|
||
}
|
||
.zd-by {
|
||
flex: 1;
|
||
min-width: 0;
|
||
}
|
||
.zd-nick {
|
||
display: block;
|
||
font-size: 14px;
|
||
font-weight: 600;
|
||
}
|
||
.zd-time {
|
||
display: block;
|
||
font-size: 11px;
|
||
color: #64748b;
|
||
margin-top: 2px;
|
||
}
|
||
.zd-md {
|
||
margin-bottom: 16px;
|
||
}
|
||
.zd-md :global(.md-root),
|
||
.zd-md :global(.md-p),
|
||
.zd-md :global(.md-li) {
|
||
font-size: 16px !important;
|
||
line-height: 1.75 !important;
|
||
color: #e8eef7 !important;
|
||
}
|
||
.zd-imgs {
|
||
display: flex;
|
||
flex-direction: column;
|
||
gap: 10px;
|
||
margin-bottom: 16px;
|
||
}
|
||
.zd-img {
|
||
width: 100%;
|
||
border-radius: 12px;
|
||
background: #0f172a;
|
||
}
|
||
.zd-tags {
|
||
display: flex;
|
||
flex-wrap: wrap;
|
||
gap: 8px;
|
||
margin-bottom: 8px;
|
||
}
|
||
.zd-tag {
|
||
font-size: 12px;
|
||
color: #f59e0b;
|
||
background: rgba(245, 158, 11, 0.1);
|
||
padding: 4px 10px;
|
||
border-radius: 999px;
|
||
}
|
||
.zd-section {
|
||
padding: 8px 18px 28px;
|
||
}
|
||
.zd-section-title {
|
||
display: block;
|
||
font-size: 14px;
|
||
font-weight: 700;
|
||
color: #cbd5e1;
|
||
margin-bottom: 12px;
|
||
}
|
||
.zd-cmt {
|
||
padding: 12px 0;
|
||
border-bottom: 1px solid rgba(255, 255, 255, 0.05);
|
||
}
|
||
.zd-cmt-nick {
|
||
display: block;
|
||
font-size: 12px;
|
||
font-weight: 600;
|
||
color: #f59e0b;
|
||
margin-bottom: 4px;
|
||
}
|
||
.zd-cmt-body {
|
||
display: block;
|
||
font-size: 14px;
|
||
line-height: 1.5;
|
||
}
|
||
.zd-cmt-time {
|
||
display: block;
|
||
font-size: 11px;
|
||
color: #64748b;
|
||
margin-top: 4px;
|
||
}
|
||
.zd-empty {
|
||
display: block;
|
||
font-size: 12px;
|
||
color: #64748b;
|
||
padding: 12px 0;
|
||
}
|
||
.zd-bar {
|
||
position: fixed;
|
||
left: 0;
|
||
right: 0;
|
||
bottom: 0;
|
||
display: flex;
|
||
gap: 8px;
|
||
align-items: center;
|
||
padding: 8px 12px calc(8px + env(safe-area-inset-bottom));
|
||
background: rgba(12, 12, 15, 0.96);
|
||
border-top: 1px solid rgba(255, 255, 255, 0.06);
|
||
backdrop-filter: blur(12px);
|
||
}
|
||
.zd-bar-acts {
|
||
display: flex;
|
||
gap: 10px;
|
||
flex-shrink: 0;
|
||
}
|
||
.zd-act {
|
||
font-size: 13px;
|
||
color: #94a3b8;
|
||
min-height: 36px;
|
||
display: flex;
|
||
align-items: center;
|
||
padding: 0 4px;
|
||
}
|
||
.zd-act.on {
|
||
color: #f59e0b;
|
||
}
|
||
.zd-input {
|
||
flex: 1;
|
||
background: rgba(255, 255, 255, 0.06);
|
||
border-radius: 10px;
|
||
padding: 8px 12px;
|
||
font-size: 14px;
|
||
color: #e8eef7;
|
||
min-width: 0;
|
||
}
|
||
.zd-send {
|
||
background: #f59e0b !important;
|
||
color: #0c0c0f !important;
|
||
border: none !important;
|
||
border-radius: 10px !important;
|
||
font-size: 13px !important;
|
||
font-weight: 700 !important;
|
||
margin: 0 !important;
|
||
padding: 0 14px !important;
|
||
line-height: 36px !important;
|
||
flex-shrink: 0;
|
||
}
|