HTML5 在线漫画阅读器 (index.html)
<!DOCTYPE html>
<html lang="zh-CN">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width,initial-scale=1,maximum-scale=3,user-scalable=yes">
<title>信蜂 - 在线漫画阅读器</title>
<style>
*{box-sizing:border-box;margin:0;padding:0}
body{background:#0d0f17;color:#f1f5f9;font-family:-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,sans-serif;min-height:100vh;display:flex;flex-direction:column}
header{position:sticky;top:0;z-index:50;background:rgba(13,15,23,0.92);backdrop-filter:blur(12px);border-bottom:1px solid rgba(255,255,255,0.09);padding:10px 16px;display:flex;align-items:center;justify-content:space-between;gap:10px;flex-wrap:wrap}
.brand{display:flex;align-items:center;gap:10px}
.badge{background:linear-gradient(135deg,#ec4899,#8b5cf6);color:#fff;font-size:11px;font-weight:700;padding:3px 8px;border-radius:99px}
.title{font-size:16px;font-weight:700;color:#fff}
.controls{display:flex;align-items:center;gap:8px;flex-wrap:wrap}
button{background:rgba(255,255,255,0.08);color:#e2e8f0;border:1px solid rgba(255,255,255,0.14);padding:6px 12px;border-radius:8px;font-size:12px;cursor:pointer;transition:.18s}
button:hover,button.active{background:#ec4899;color:#fff;border-color:#ec4899}
.hero{max-width:920px;margin:16px auto;padding:18px;background:rgba(255,255,255,0.04);border:1px solid rgba(255,255,255,0.08);border-radius:14px;display:flex;gap:18px;align-items:flex-start}
.hero img{width:120px;height:160px;object-fit:cover;border-radius:10px;flex-shrink:0;box-shadow:0 8px 24px rgba(0,0,0,0.45)}
.hero-meta h1{font-size:20px;margin-bottom:6px}
.hero-meta .sub{font-size:13px;color:#94a3b8;margin-bottom:8px}
.tags{display:flex;gap:6px;flex-wrap:wrap;margin-bottom:10px}
.tag{background:rgba(236,72,153,0.16);color:#f472b6;padding:2px 8px;border-radius:6px;font-size:11px}
.desc{font-size:13px;line-height:1.6;color:#cbd5e1}
.reader-wrap{max-width:860px;width:100%;margin:0 auto 40px;padding:0 8px;flex:1}
.scroll-mode .page-card{margin-bottom:10px;background:#161925;border-radius:8px;overflow:hidden;box-shadow:0 6px 20px rgba(0,0,0,0.4)}
.scroll-mode .page-card img{width:100%;height:auto;display:block}
.page-footer{text-align:center;font-size:11px;color:#64748b;padding:4px 0}
.flip-controls{display:none;justify-content:center;align-items:center;gap:14px;margin:14px 0}
.flip-mode .flip-controls{display:flex}
.drawer{display:none;max-width:920px;margin:0 auto 20px;padding:16px;background:rgba(255,255,255,0.04);border-radius:12px;border:1px solid rgba(255,255,255,0.1)}
.drawer.open{display:block}
.chap-grid{display:grid;grid-template-columns:repeat(auto-fill,minmax(170px,1fr));gap:8px;margin-top:10px}
.chap-item{padding:8px 10px;background:rgba(255,255,255,0.06);border-radius:8px;font-size:12px;color:#e2e8f0;cursor:pointer;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.chap-item:hover{background:rgba(236,72,153,0.28)}
@media(max-width:600px){.hero{flex-direction:column;align-items:center;text-align:center}.tags{justify-content:center}}
</style>
</head>
<body>
<header>
<div class="brand">
<span class="badge">BILIMANGA · 统一媒体库</span>
<span class="title" id="hdrTitle"></span>
</div>
<div class="controls">
<button id="btnScroll" class="active" onclick="setMode('scroll')">条漫下拉模式</button>
<button id="btnFlip" onclick="setMode('flip')">单页翻页模式</button>
<button onclick="toggleCatalog()">章节目录 (<span id="chapCount">0</span>)</button>
<button onclick="cycleLang()" id="btnLang">繁/簡/EN</button>
</div>
</header>
<section class="hero">
<img id="heroCover" src="" alt="cover">
<div class="hero-meta">
<h1 id="heroTitle"></h1>
<div class="sub" id="heroSub"></div>
<div class="tags" id="heroTags"></div>
<p class="desc" id="heroDesc"></p>
</div>
</section>
<section class="drawer" id="catDrawer">
<h3 style="font-size:14px;margin-bottom:6px">全卷章节目录 (点击切换预览章节)</h3>
<div class="chap-grid" id="chapGrid"></div>
</section>
<div class="reader-wrap scroll-mode" id="readerWrap">
<div class="flip-controls">
<button onclick="stepPage(-1)">◀ 上一页</button>
<span id="pageIndicator" style="font-size:13px;color:#cbd5e1">1 / 1</span>
<button onclick="stepPage(1)">下一页 ▶</button>
</div>
<div id="pagesContainer"></div>
</div>
<script>
const COMIC = {"slug": "bilimanga-1554", "mangaid": "1554", "zh_title": "信蜂", "hant_title": "信蜂", "en_title": "信蜂 (Bilimanga #1554)", "author": "浅田弘幸", "tags": ["奇幻", "冒险", "职场", "战斗", "黑暗", "奇幻冒险", "日本漫画", "漫画"], "zh_desc": "「人心」该如何传递?「信蜂」告诉你!!\n\r\n在没有白天的地方•安帕葛兰多(AG),有种职业是专为住在连首都的人工太阳都照射不到的危险地区的人们送信,他们赌上性命般的将人们托付给他们的〝心〞努力送达,大家都称他们为「信蜂」!\n\n📚 作品信息:作者 浅田弘幸 · 评分 10 · 共收录 20 卷 / 119 话章节目录与高清彩页/条漫预览。", "hant_desc": "「人心」該如何傳遞?「信蜂」告訴你!!\n\r\n在沒有白天的地方•安帕葛蘭多(AG),有種職業是專為住在連首都的人工太陽都照射不到的危險地區的人們送信,他們賭上性命般的將人們託付給他們的〝心〞努力送達,大家都稱他們為「信蜂」!\n\n📚 作品資訊:作者 淺田弘幸 · 評分 10 · 共收錄 20 卷 / 119 話章節目錄與高清彩頁/條漫預覽。", "en_desc": "Popular serialized manga '信蜂' (信蜂) by 浅田弘幸. Includes 20 volumes and 119 chapters with full online vertical/page-flip web reader.", "pages": ["https://media.huangguodrama.ai/motion/comics/bilimanga-1554/page_01.jpg", "https://media.huangguodrama.ai/motion/comics/bilimanga-1554/page_02.jpg", "https://media.huangguodrama.ai/motion/comics/bilimanga-1554/page_03.jpg", "https://media.huangguodrama.ai/motion/comics/bilimanga-1554/page_04.jpg", "https://media.huangguodrama.ai/motion/comics/bilimanga-1554/page_05.jpg", "https://media.huangguodrama.ai/motion/comics/bilimanga-1554/page_06.jpg"], "volumes": [{"title_hant": "信蜂 1", "title_zh": "信蜂 1", "cover_id": 2816704, "first_chap_id": 128980, "cover_url": "https://i.motiezw.com/cover/1554/2816704.jpg"}, {"title_hant": "信蜂 2", "title_zh": "信蜂 2", "cover_id": 2816891, "first_chap_id": 128986, "cover_url": "https://i.motiezw.com/cover/1554/2816891.jpg"}, {"title_hant": "信蜂 3", "title_zh": "信蜂 3", "cover_id": 2817076, "first_chap_id": 128992, "cover_url": "https://i.motiezw.com/cover/1554/2817076.jpg"}, {"title_hant": "信蜂 4", "title_zh": "信蜂 4", "cover_id": 2817259, "first_chap_id": 129000, "cover_url": "https://i.motiezw.com/cover/1554/2817259.jpg"}, {"title_hant": "信蜂 5", "title_zh": "信蜂 5", "cover_id": 2817436, "first_chap_id": 129006, "cover_url": "https://i.motiezw.com/cover/1554/2817436.jpg"}, {"title_hant": "信蜂 6", "title_zh": "信蜂 6", "cover_id": 2817617, "first_chap_id": 129012, "cover_url": "https://i.motiezw.com/cover/1554/2817617.jpg"}, {"title_hant": "信蜂 7", "title_zh": "信蜂 7", "cover_id": 2817797, "first_chap_id": 129018, "cover_url": "https://i.motiezw.com/cover/1554/2817797.jpg"}, {"title_hant": "信蜂 8", "title_zh": "信蜂 8", "cover_id": 2817967, "first_chap_id": 129024, "cover_url": "https://i.motiezw.com/cover/1554/2817967.jpg"}, {"title_hant": "信蜂 9", "title_zh": "信蜂 9", "cover_id": 2818147, "first_chap_id": 129030, "cover_url": "https://i.motiezw.com/cover/1554/2818147.jpg"}, {"title_hant": "信蜂 10", "title_zh": "信蜂 10", "cover_id": 2818324, "first_chap_id": 129036, "cover_url": "https://i.motiezw.com/cover/1554/2818324.jpg"}, {"title_hant": "信蜂 11", "title_zh": "信蜂 11", "cover_id": 2818505, "first_chap_id": 129043, "cover_url": "https://i.motiezw.com/cover/1554/2818505.jpg"}, {"title_hant": "信蜂 12", "title_zh": "信蜂 12", "cover_id": 2818690, "first_chap_id": 129050, "cover_url": "https://i.motiezw.com/cover/1554/2818690.jpg"}], "chapters": [{"cid": "128980", "title": "第1話「信件與信蜂」①", "title_zh": "第1话「信件与信蜂」①"}, {"cid": "128981", "title": "第1話「信件與信蜂」②", "title_zh": "第1话「信件与信蜂」②"}, {"cid": "128982", "title": "第1話「信件與信蜂」③", "title_zh": "第1话「信件与信蜂」③"}, {"cid": "128983", "title": "第2話「愛哭鬼少年、信件少N」①", "title_zh": "第2话「爱哭鬼少年、信件少N」①"}, {"cid": "128984", "title": "第2話「愛哭鬼少年、信件少N」②", "title_zh": "第2话「爱哭鬼少年、信件少N」②"}, {"cid": "128996", "title": "附錄", "title_zh": "附录"}, {"cid": "128986", "title": "第3話 給基奇・培帕的信/前篇", "title_zh": "第3话 给基奇・培帕的信/前篇"}, {"cid": "128987", "title": "第4話 給基奇・培帕的信/中篇", "title_zh": "第4话 给基奇・培帕的信/中篇"}, {"cid": "128988", "title": "第5話 給基奇・培帕的信/後篇", "title_zh": "第5话 给基奇・培帕的信/后篇"}, {"cid": "128989", "title": "第6話 尤烏薩利中央夜想道13號郵便館BEE-HIVE", "title_zh": "第6话 尤乌萨利中央夜想道13号邮便馆BEE-HIVE"}, {"cid": "128990", "title": "第7話 木莓之丘", "title_zh": "第7话 木莓之丘"}, {"cid": "128997", "title": "附錄", "title_zh": "附录"}, {"cid": "128992", "title": "第8話 與希爾貝特・史衛特見面", "title_zh": "第8话 与希尔贝特・史卫特见面"}, {"cid": "128993", "title": "第9話 愛哭鬼少年的誓言", "title_zh": "第9话 爱哭鬼少年的誓言"}, {"cid": "128994", "title": "第10話 光之下", "title_zh": "第10话 光之下"}, {"cid": "128995", "title": "特別篇 信蜂與叮鈴", "title_zh": "特别篇 信蜂与叮铃"}, {"cid": "128998", "title": "附錄", "title_zh": "附录"}, {"cid": "129000", "title": "第11話 謊言之信", "title_zh": "第11话 谎言之信"}, {"cid": "129001", "title": "第12話 死屍博士", "title_zh": "第12话 死尸博士"}, {"cid": "129002", "title": "第13話 甜蜜之水", "title_zh": "第13话 甜蜜之水"}, {"cid": "129004", "title": "附錄", "title_zh": "附录"}, {"cid": "129006", "title": "第15話 三個心的記憶", "title_zh": "第15话 三个心的记忆"}, {"cid": "129007", "title": "第16話 無法成為精靈的人", "title_zh": "第16话 无法成为精灵的人"}, {"cid": "129008", "title": "第17話 再會、眼淚、眼淚、眼淚", "title_zh": "第17话 再会、眼泪、眼泪、眼泪"}, {"cid": "129009", "title": "第18話 NK與麵包", "title_zh": "第18话 NK与面包"}, {"cid": "129010", "title": "附錄", "title_zh": "附录"}, {"cid": "129012", "title": "第19話 紫陽花S的信件畫", "title_zh": "第19话 紫阳花S的信件画"}, {"cid": "129013", "title": "第20話 荒野幻燈塔", "title_zh": "第20话 荒野幻灯塔"}, {"cid": "129014", "title": "第21話 少N人形", "title_zh": "第21话 少N人形"}, {"cid": "129015", "title": "第22話 Film noir", "title_zh": "第22话 Film noir"}, {"cid": "129016", "title": "附錄", "title_zh": "附录"}, {"cid": "129018", "title": "第23話 青S諾茲藍調", "title_zh": "第23话 青S诺兹蓝调"}, {"cid": "129019", "title": "第24話 摩訶與人", "title_zh": "第24话 摩诃与人"}, {"cid": "129020", "title": "第25話 孤寂兩百年", "title_zh": "第25话 孤寂两百年"}, {"cid": "129021", "title": "第26話 精靈庭院", "title_zh": "第26话 精灵庭院"}, {"cid": "129022", "title": "附錄", "title_zh": "附录"}, {"cid": "129024", "title": "第27話 貝莉塔普利修道院", "title_zh": "第27话 贝莉塔普利修道院"}, {"cid": "129025", "title": "第28話 兩人,曾經旅行過⋯", "title_zh": "第28话 两人,曾经旅行过⋯"}, {"cid": "129026", "title": "第29話 光芒,將照亮黑暗", "title_zh": "第29话 光芒,将照亮黑暗"}, {"cid": "129027", "title": "第30話 一定會", "title_zh": "第30话 一定会"}, {"cid": "129030", "title": "第31話 回館", "title_zh": "第31话 回馆"}, {"cid": "129031", "title": "第32話 首都監察員", "title_zh": "第32话 首都监察员"}, {"cid": "129032", "title": "第33話 凍結信件課", "title_zh": "第33话 冻结信件课"}, {"cid": "129033", "title": "第34話 石頭之愛", "title_zh": "第34话 石头之爱"}, {"cid": "129034", "title": "附錄", "title_zh": "附录"}, {"cid": "129036", "title": "第35話 安利亞與飛行船", "title_zh": "第35话 安利亚与飞行船"}, {"cid": "129037", "title": "第36話 勇者波魯托", "title_zh": "第36话 勇者波鲁托"}, {"cid": "129038", "title": "第37話 霍戴・富蘭克林", "title_zh": "第37话 霍戴・富兰克林"}, {"cid": "129039", "title": "第38話 發光的眼", "title_zh": "第38话 发光的眼"}, {"cid": "129040", "title": "第39話 無法成為精靈的狼", "title_zh": "第39话 无法成为精灵的狼"}, {"cid": "129041", "title": "附錄", "title_zh": "附录"}, {"cid": "129043", "title": "第40話 轉折點", "title_zh": "第40话 转折点"}, {"cid": "129044", "title": "第41話 回家", "title_zh": "第41话 回家"}, {"cid": "129045", "title": "第42話 BEE的背袋", "title_zh": "第42话 BEE的背袋"}, {"cid": "129046", "title": "第43話 在內心深處", "title_zh": "第43话 在内心深处"}, {"cid": "129047", "title": "第44話 寂靜與追擊", "title_zh": "第44话 寂静与追击"}, {"cid": "129048", "title": "附錄", "title_zh": "附录"}, {"cid": "129050", "title": "第45話 心的聲音", "title_zh": "第45话 心的声音"}, {"cid": "129051", "title": "第46話 威脅逼近", "title_zh": "第46话 威胁逼近"}, {"cid": "129052", "title": "第47話 光之子", "title_zh": "第47话 光之子"}]};
let lang = 'zh';
let mode = 'scroll';
let curPage = 0;
function renderMeta() {
const t = lang === 'zh' ? COMIC.zh_title : (lang === 'hant' ? COMIC.hant_title : COMIC.en_title);
const d = lang === 'zh' ? COMIC.zh_desc : (lang === 'hant' ? COMIC.hant_desc : COMIC.en_desc);
document.getElementById('hdrTitle').textContent = t;
document.getElementById('heroTitle').textContent = t;
document.getElementById('heroSub').textContent = `${COMIC.author} · 共 ${COMIC.volumes.length} 卷 / ${COMIC.chapters.length} 话`;
document.getElementById('heroDesc').textContent = d;
document.getElementById('heroCover').src = COMIC.pages[0] || '';
document.getElementById('chapCount').textContent = COMIC.chapters.length;
const tg = document.getElementById('heroTags');
tg.innerHTML = '';
(COMIC.tags || []).forEach(x => {
const s = document.createElement('span');
s.className = 'tag';
s.textContent = x;
tg.appendChild(s);
});
}
function renderCatalog() {
const g = document.getElementById('chapGrid');
g.innerHTML = '';
(COMIC.chapters || []).forEach((c, idx) => {
const d = document.createElement('div');
d.className = 'chap-item';
d.textContent = c.title_zh || c.title;
d.onclick = () => {
curPage = idx % COMIC.pages.length;
if (mode === 'flip') renderPages();
else document.querySelectorAll('.page-card')[curPage]?.scrollIntoView({behavior:'smooth'});
document.getElementById('catDrawer').classList.remove('open');
};
g.appendChild(d);
});
}
function renderPages() {
const wrap = document.getElementById('readerWrap');
wrap.className = 'reader-wrap ' + (mode === 'scroll' ? 'scroll-mode' : 'flip-mode');
const box = document.getElementById('pagesContainer');
box.innerHTML = '';
const list = mode === 'scroll' ? COMIC.pages : [COMIC.pages[curPage]];
list.forEach((url, i) => {
const idx = mode === 'scroll' ? i : curPage;
const card = document.createElement('div');
card.className = 'page-card';
card.innerHTML = `<img src="${url}" loading="lazy" alt="Page ${idx+1}"><div class="page-footer">第 ${idx+1} / ${COMIC.pages.length} 页 · ${COMIC.zh_title}</div>`;
if (mode === 'flip') card.onclick = () => stepPage(1);
box.appendChild(card);
});
document.getElementById('pageIndicator').textContent = `${curPage + 1} / ${COMIC.pages.length}`;
}
function setMode(m) {
mode = m;
document.getElementById('btnScroll').classList.toggle('active', m === 'scroll');
document.getElementById('btnFlip').classList.toggle('active', m === 'flip');
renderPages();
}
function stepPage(delta) {
curPage = (curPage + delta + COMIC.pages.length) % COMIC.pages.length;
renderPages();
}
function toggleCatalog() {
document.getElementById('catDrawer').classList.toggle('open');
}
function cycleLang() {
lang = lang === 'zh' ? 'hant' : (lang === 'hant' ? 'en' : 'zh');
renderMeta();
}
renderMeta();
renderCatalog();
renderPages();
</script>
</body>
</html>