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-1105", "mangaid": "1105", "zh_title": "这样算是僵尸吗?", "hant_title": "這樣算是殭屍嗎?", "en_title": "这样算是僵尸吗? (Bilimanga #1105)", "author": "さっち / 木村心一 / こぶいち, むりりん", "tags": ["奇幻", "战斗", "异能", "后宫", "伪娘", "欢乐", "奇幻冒险", "日本漫画"], "zh_desc": "被卷入连续杀人案而被杀的相川步为什么还活著?\n\r\n复活的他除了既是僵尸,也是魔装少女之外,\n\r\n还引来死灵法师少女、魔装少女再加上吸血忍者都跟他住在一起…\n\r\n超人气同名轻小说漫画版登场!\n\n📚 作品信息:作者 さっち / 木村心一 / こぶいち, むりりん · 评分 10 · 共收录 8 卷 / 52 话章节目录与高清彩页/条漫预览。", "hant_desc": "被捲入連續殺人案而被殺的相川步為什麼還活著?\n\r\n復活的他除了既是殭屍,也是魔裝少女之外,\n\r\n還引來死靈法師少女、魔裝少女再加上吸血忍者都跟他住在一起…\n\r\n超人氣同名輕小說漫畫版登場!\n\n📚 作品資訊:作者 さっち / 木村心一 / こぶいち, むりりん · 評分 10 · 共收錄 8 卷 / 52 話章節目錄與高清彩頁/條漫預覽。", "en_desc": "Popular serialized manga '这样算是僵尸吗?' (這樣算是殭屍嗎?) by さっち / 木村心一 / こぶいち, むりりん. Includes 8 volumes and 52 chapters with full online vertical/page-flip web reader.", "pages": ["https://media.huangguodrama.ai/motion/comics/bilimanga-1105/page_01.jpg", "https://media.huangguodrama.ai/motion/comics/bilimanga-1105/page_02.jpg", "https://media.huangguodrama.ai/motion/comics/bilimanga-1105/page_03.jpg", "https://media.huangguodrama.ai/motion/comics/bilimanga-1105/page_04.jpg", "https://media.huangguodrama.ai/motion/comics/bilimanga-1105/page_05.jpg", "https://media.huangguodrama.ai/motion/comics/bilimanga-1105/page_06.jpg"], "volumes": [{"title_hant": "這樣算是殭屍嗎? 1", "title_zh": "这样算是僵尸吗? 1", "cover_id": 1988714, "first_chap_id": 92918, "cover_url": "https://i.motiezw.com/cover/1105/1988714.jpg"}, {"title_hant": "這樣算是殭屍嗎? 2", "title_zh": "这样算是僵尸吗? 2", "cover_id": 1988881, "first_chap_id": 92925, "cover_url": "https://i.motiezw.com/cover/1105/1988881.jpg"}, {"title_hant": "這樣算是殭屍嗎? 3", "title_zh": "这样算是僵尸吗? 3", "cover_id": 1989044, "first_chap_id": 92932, "cover_url": "https://i.motiezw.com/cover/1105/1989044.jpg"}, {"title_hant": "這樣算是殭屍嗎? 4", "title_zh": "这样算是僵尸吗? 4", "cover_id": 1989210, "first_chap_id": 92940, "cover_url": "https://i.motiezw.com/cover/1105/1989210.jpg"}, {"title_hant": "這樣算是殭屍嗎? 5", "title_zh": "这样算是僵尸吗? 5", "cover_id": 1989376, "first_chap_id": 92948, "cover_url": "https://i.motiezw.com/cover/1105/1989376.jpg"}, {"title_hant": "這樣算是殭屍嗎? 6", "title_zh": "这样算是僵尸吗? 6", "cover_id": 1989538, "first_chap_id": 92956, "cover_url": "https://i.motiezw.com/cover/1105/1989538.jpg"}, {"title_hant": "這樣算是殭屍嗎? 7", "title_zh": "这样算是僵尸吗? 7", "cover_id": 1989705, "first_chap_id": 92964, "cover_url": "https://i.motiezw.com/cover/1105/1989705.jpg"}, {"title_hant": "這樣算是殭屍嗎? 8", "title_zh": "这样算是僵尸吗? 8", "cover_id": 1989872, "first_chap_id": 92972, "cover_url": "https://i.motiezw.com/cover/1105/1989872.jpg"}], "chapters": [{"cid": "92918", "title": "第一話 是的,這是魔装少N!", "title_zh": "第一话 是的,这是魔装少N!"}, {"cid": "92919", "title": "第二話 對,我是死亡召喚者", "title_zh": "第二话 对,我是死亡召唤者"}, {"cid": "92920", "title": "第三話 快念咒语啦!", "title_zh": "第三话 快念咒语啦!"}, {"cid": "92921", "title": "第四話 ⋯⋯鳴啾——", "title_zh": "第四话 ⋯⋯鸣啾——"}, {"cid": "92922", "title": "第五話 步⋯⋯我沒吃過日式料理以外的食物", "title_zh": "第五话 步⋯⋯我没吃过日式料理以外的食物"}, {"cid": "92923", "title": "出差版 想讓你的部落格被灌爆嗎!?", "title_zh": "出差版 想让你的部落格被灌爆吗!?"}, {"cid": "92925", "title": "第六話 步肯定會是豬", "title_zh": "第六话 步肯定会是猪"}, {"cid": "92926", "title": "第七話 死吧", "title_zh": "第七话 死吧"}, {"cid": "92927", "title": "第八話 並不讨厌", "title_zh": "第八话 并不讨厌"}, {"cid": "92928", "title": "第九話 什麼~~~!!", "title_zh": "第九话 什么~~~!!"}, {"cid": "92929", "title": "第十話 啊!?⋯⋯是香腸?", "title_zh": "第十话 啊!?⋯⋯是香肠?"}, {"cid": "92930", "title": "出差版 是的,這是四格漫畫", "title_zh": "出差版 是的,这是四格漫画"}, {"cid": "92932", "title": "第十一話 那是翱翔天際的必殺雷霆戰機", "title_zh": "第十一话 那是翱翔天际的必杀雷霆战机"}, {"cid": "92933", "title": "第十二話 太~不~講~理~了~吧?", "title_zh": "第十二话 太~不~讲~理~了~吧?"}, {"cid": "92934", "title": "第十三話 不用管我,快點煎——!", "title_zh": "第十三话 不用管我,快点煎——!"}, {"cid": "92935", "title": "第十四話 舉杯同酌", "title_zh": "第十四话 举杯同酌"}, {"cid": "92936", "title": "第十五話 你就是殭屍嗎?", "title_zh": "第十五话 你就是僵尸吗?"}, {"cid": "92937", "title": "第十六話 優⋯優⋯優克莉", "title_zh": "第十六话 优⋯优⋯优克莉"}, {"cid": "92938", "title": "附錄", "title_zh": "附录"}, {"cid": "92940", "title": "第十七話 約、約、約會——!", "title_zh": "第十七话 约、约、约会——!"}, {"cid": "92942", "title": "第十九話 喵⋯喵呜!", "title_zh": "第十九话 喵⋯喵呜!"}, {"cid": "92943", "title": "第二十話 做得很不錯啊——", "title_zh": "第二十话 做得很不错啊——"}, {"cid": "92944", "title": "第二十一話 哇啊啊啊!瑟拉好S", "title_zh": "第二十一话 哇啊啊啊!瑟拉好S"}, {"cid": "92945", "title": "第二十二話 来吧!", "title_zh": "第二十二话 来吧!"}, {"cid": "92946", "title": "附錄", "title_zh": "附录"}, {"cid": "92948", "title": "第二十三話 為什麼連我的份都有啊", "title_zh": "第二十三话 为什么连我的份都有啊"}, {"cid": "92949", "title": "第二十四話 你好好看著吧!", "title_zh": "第二十四话 你好好看著吧!"}, {"cid": "92950", "title": "第二十五話 唔——————!", "title_zh": "第二十五话 唔——————!"}, {"cid": "92951", "title": "第二十六話 千萬不要按(笑)", "title_zh": "第二十六话 千万不要按(笑)"}, {"cid": "92952", "title": "第二十七話 想死的就給我站出來!", "title_zh": "第二十七话 想死的就给我站出来!"}, {"cid": "92953", "title": "這樣算是新稿嗎? 啊~好棒的泡湯啊~", "title_zh": "这样算是新稿吗? 啊~好棒的泡汤啊~"}, {"cid": "92954", "title": "附錄", "title_zh": "附录"}, {"cid": "92956", "title": "第二十八話 對⋯對不起啦", "title_zh": "第二十八话 对⋯对不起啦"}, {"cid": "92957", "title": "第二十九話 她是個宅N?", "title_zh": "第二十九话 她是个宅N?"}, {"cid": "92958", "title": "第三十話 星光粉碎☆乾杯!", "title_zh": "第三十话 星光粉碎☆干杯!"}, {"cid": "92959", "title": "第三十一話 Yeah☆", "title_zh": "第三十一话 Yeah☆"}, {"cid": "92960", "title": "第三十二話 妳一真是個天才", "title_zh": "第三十二话 妳一真是个天才"}, {"cid": "92961", "title": "第三十三話 讓專業的來——!", "title_zh": "第三十三话 让专业的来——!"}, {"cid": "92962", "title": "附錄", "title_zh": "附录"}, {"cid": "92964", "title": "第三十四話 我們來親親吧——", "title_zh": "第三十四话 我们来亲亲吧——"}, {"cid": "92965", "title": "第三十五話 逮到妳了——!!", "title_zh": "第三十五话 逮到妳了——!!"}, {"cid": "92967", "title": "第三十七話 來吧!我們來過聖誕節!", "title_zh": "第三十七话 来吧!我们来过圣诞节!"}, {"cid": "92968", "title": "第三十八話 妖精☆亂舞", "title_zh": "第三十八话 妖精☆乱舞"}, {"cid": "92969", "title": "第三十九話 喵————————!", "title_zh": "第三十九话 喵————————!"}, {"cid": "92970", "title": "附錄", "title_zh": "附录"}, {"cid": "92972", "title": "第四十話 住手!住手,●卡軍團!", "title_zh": "第四十话 住手!住手,●卡军团!"}, {"cid": "92973", "title": "第四十一話 下場如何呀?相·川~?", "title_zh": "第四十一话 下场如何呀?相·川~?"}, {"cid": "92974", "title": "第四十二話 F91!!", "title_zh": "第四十二话 F91!!"}, {"cid": "92975", "title": "第四十三話 屁股特別讓人受不了", "title_zh": "第四十三话 屁股特别让人受不了"}, {"cid": "92976", "title": "第四十四話 我還以為你們做了少子化對策呢", "title_zh": "第四十四话 我还以为你们做了少子化对策呢"}, {"cid": "92977", "title": "第四十五話 我是最強的!", "title_zh": "第四十五话 我是最强的!"}, {"cid": "92978", "title": "附錄", "title_zh": "附录"}]};
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>