diff --git a/guangchang/index.html b/guangchang/index.html index 50a4e03..3aa2706 100644 --- a/guangchang/index.html +++ b/guangchang/index.html @@ -484,6 +484,19 @@ button{font:inherit;color:inherit;border:0;background:none;padding:0;cursor:poin /* 11-05 整合:投稿奖励一行(原在热门话题列表头)+ 选中标签后的热门话题 */ .rww{margin:14px 12px 0} .rww .rwl{margin:0} +/* 11-07 用户:祈福树下面「投稿被选中得 ¥30…」一条 → 改成轮播「哪些妈妈的笔记上了广场」:真实投稿(审核通过)排前, + 不够时用广场里点赞高的笔记补;只说「上了广场 / 入选精选」,不写某人领了多少钱。右边「我也投稿」= 原来的规则弹层 */ +.rwc{display:flex;align-items:center;gap:8px;height:40px;padding:0 6px 0 10px;border-radius:12px;background:linear-gradient(100deg,#FFF1E8,#FFE6E6)} +.rwc>.ic{flex:none;width:16px;height:16px;color:#F2553A} +.rwv{position:relative;flex:1;min-width:0;height:40px;overflow:hidden} +.rwi{position:absolute;left:0;right:0;top:0;display:flex;align-items:center;gap:6px;height:40px;border:0;background:none;padding:0;font:inherit;text-align:left;color:#8A4B36;font-size:12px; + transition:transform .4s ease,opacity .4s ease} +.rwi.in{transform:translateY(100%);opacity:0}.rwi.out{transform:translateY(-100%);opacity:0} +.rwi img{flex:none;width:20px;height:20px;border-radius:50%;object-fit:cover;background:#FFE3D3} +.rwi span{flex:1;min-width:0;white-space:nowrap;overflow:hidden;text-overflow:ellipsis} +.rwi span b{font-weight:800;color:#5A3226} +.rwi span em{font-style:normal;font-weight:800;color:#F2394A} +.rwb{flex:none;height:26px;padding:0 10px;border:0;border-radius:99px;background:linear-gradient(135deg,#FF8A65,#F2553A);color:#fff;font:inherit;font-size:11.5px;font-weight:800} .gtp{display:flex;flex-direction:column;align-items:flex-start;gap:6px;margin:2px 14px 4px;padding:10px 12px;border-radius:14px;background:#fff;box-shadow:0 6px 16px -14px rgba(120,60,40,.35)} .gtp[hidden]{display:none} .gtp-h{font-size:11.5px;font-weight:800;color:#F2553A} @@ -1652,6 +1665,33 @@ html.night .gtg button.on{background:#F2725B;border-color:#F2725B;color:#fff} bx.hidden = !tl.length; bx.innerHTML = '热门话题' + tl.map(function (x) { return ''; }).join(''); } + /* ---------- 「谁的笔记上了广场」轮播(11-07) ---------- */ + var rwI = 0, rwT = null; + function rwList() { + var real = NOTES.filter(function (n) { return n.real; }).slice(0, 10); + var pick = NOTES.filter(function (n) { return !n.real && n.photo; }).sort(function (a, b) { return b.likes - a.likes; }); + var seen = {}, mock = []; + pick.forEach(function (n) { if (mock.length < 12 && !seen[n.author]) { seen[n.author] = 1; mock.push(n); } }); + return real.concat(mock); + } + function rwItem(k) { + var L = rwList(); if (!L.length) return ''; + var n = L[k % L.length], tt = n.title.length > 14 ? n.title.slice(0, 13) + '…' : n.title; + return ''; + } + function rwRun() { + clearInterval(rwT); rwI = 0; + if (rwList().length < 2) return; + rwT = setInterval(function () { + var box = document.getElementById('rwv'); if (!box) { clearInterval(rwT); return; } + if (document.hidden || openId) return; + var old = box.firstElementChild; rwI++; + box.insertAdjacentHTML('beforeend', rwItem(rwI)); + var nw = box.lastElementChild; nw.classList.add('in'); void nw.offsetWidth; + nw.classList.remove('in'); if (old) { old.classList.add('out'); setTimeout(function () { if (old.parentNode) old.remove(); }, 420); } + }, 3200); + } function renderHead() { var t = TBY[cur], el = $('#head'), fh = $('#fh'); var fl0 = document.getElementById('luckFl'); if (fl0) fl0.classList.remove('on'); @@ -1661,7 +1701,8 @@ html.night .gtg button.on{background:#F2725B;border-color:#F2725B;color:#fff} 标签作为唯一入口(末尾加「全部话题 ›」);选中标签时标签下露出这一类的 2~3 个热门话题(用户同意);投稿奖励一行挪到「大家在聊」上面。 话题本身不变:投稿选话题、帖子卡上的 #话题#、话题详情页照旧。分类视图(catF)仍是原来的热门话题列表。 */ el.innerHTML = qifuHTML() + - '
'; + '