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>HUNTER x HUNTER 猎人 全彩版 - 在线漫画阅读器</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-1148", "mangaid": "1148", "zh_title": "HUNTER x HUNTER 猎人 全彩版", "hant_title": "HUNTER x HUNTER 獵人 全彩版", "en_title": "HUNTER x HUNTER 猎人 全彩版 (Bilimanga #1148)", "author": "富坚义博", "tags": ["奇幻", "冒险", "战斗", "热血", "异能", "人外", "猎奇", "群像"], "zh_desc": "小杰是一个想要继承父亲成为一流猎人的热血少年。为了要完成这个心愿,他毅然决然参加一年一度的猎人试验,朝著未知的难关勇敢迈进…\n\r\n大师继《幽游白书》、《灵异E接触》之后又一部颠覆漫画界既有常识的长篇力作!\n\n📚 作品信息:作者 富坚义博 · 评分 10 · 共收录 36 卷 / 365 话章节目录与高清彩页/条漫预览。", "hant_desc": "小傑是一個想要繼承父親成為一流獵人的熱血少年。為了要完成這個心願,他毅然決然參加一年一度的獵人試驗,朝著未知的難關勇敢邁進…\n\r\n大師繼《幽遊白書》、《靈異E接觸》之後又一部顛覆漫畫界既有常識的長篇力作!\n\n📚 作品資訊:作者 富堅義博 · 評分 10 · 共收錄 36 卷 / 365 話章節目錄與高清彩頁/條漫預覽。", "en_desc": "Popular serialized manga 'HUNTER x HUNTER 猎人 全彩版' (HUNTER x HUNTER 獵人 全彩版) by 富坚义博. Includes 36 volumes and 365 chapters with full online vertical/page-flip web reader.", "pages": ["https://media.huangguodrama.ai/motion/comics/bilimanga-1148/page_01.jpg", "https://media.huangguodrama.ai/motion/comics/bilimanga-1148/page_02.jpg", "https://media.huangguodrama.ai/motion/comics/bilimanga-1148/page_03.jpg", "https://media.huangguodrama.ai/motion/comics/bilimanga-1148/page_04.jpg", "https://media.huangguodrama.ai/motion/comics/bilimanga-1148/page_05.jpg", "https://media.huangguodrama.ai/motion/comics/bilimanga-1148/page_06.jpg"], "volumes": [{"title_hant": "HUNTER x HUNTER 獵人 全彩版 1", "title_zh": "HUNTER x HUNTER 猎人 全彩版 1", "cover_id": 2065402, "first_chap_id": 96124, "cover_url": "https://i.motiezw.com/cover/1148/2065402.jpg"}, {"title_hant": "HUNTER x HUNTER 獵人 全彩版 2", "title_zh": "HUNTER x HUNTER 猎人 全彩版 2", "cover_id": 2065584, "first_chap_id": 96133, "cover_url": "https://i.motiezw.com/cover/1148/2065584.jpg"}, {"title_hant": "HUNTER x HUNTER 獵人 全彩版 3", "title_zh": "HUNTER x HUNTER 猎人 全彩版 3", "cover_id": 2065770, "first_chap_id": 96143, "cover_url": "https://i.motiezw.com/cover/1148/2065770.jpg"}, {"title_hant": "HUNTER x HUNTER 獵人 全彩版 4", "title_zh": "HUNTER x HUNTER 猎人 全彩版 4", "cover_id": 2065956, "first_chap_id": 96153, "cover_url": "https://i.motiezw.com/cover/1148/2065956.jpg"}, {"title_hant": "HUNTER x HUNTER 獵人 全彩版 5", "title_zh": "HUNTER x HUNTER 猎人 全彩版 5", "cover_id": 2066142, "first_chap_id": 96163, "cover_url": "https://i.motiezw.com/cover/1148/2066142.jpg"}, {"title_hant": "HUNTER x HUNTER 獵人 全彩版 6", "title_zh": "HUNTER x HUNTER 猎人 全彩版 6", "cover_id": 2066328, "first_chap_id": 96173, "cover_url": "https://i.motiezw.com/cover/1148/2066328.jpg"}, {"title_hant": "HUNTER x HUNTER 獵人 全彩版 7", "title_zh": "HUNTER x HUNTER 猎人 全彩版 7", "cover_id": 2066528, "first_chap_id": 96184, "cover_url": "https://i.motiezw.com/cover/1148/2066528.jpg"}, {"title_hant": "HUNTER x HUNTER 獵人 全彩版 8", "title_zh": "HUNTER x HUNTER 猎人 全彩版 8", "cover_id": 2066715, "first_chap_id": 96194, "cover_url": "https://i.motiezw.com/cover/1148/2066715.jpg"}, {"title_hant": "HUNTER x HUNTER 獵人 全彩版 9", "title_zh": "HUNTER x HUNTER 猎人 全彩版 9", "cover_id": 2066909, "first_chap_id": 96205, "cover_url": "https://i.motiezw.com/cover/1148/2066909.jpg"}, {"title_hant": "HUNTER x HUNTER 獵人 全彩版 10", "title_zh": "HUNTER x HUNTER 猎人 全彩版 10", "cover_id": 2067101, "first_chap_id": 96216, "cover_url": "https://i.motiezw.com/cover/1148/2067101.jpg"}, {"title_hant": "HUNTER x HUNTER 獵人 全彩版 11", "title_zh": "HUNTER x HUNTER 猎人 全彩版 11", "cover_id": 2067299, "first_chap_id": 96227, "cover_url": "https://i.motiezw.com/cover/1148/2067299.jpg"}, {"title_hant": "HUNTER x HUNTER 獵人 全彩版 12", "title_zh": "HUNTER x HUNTER 猎人 全彩版 12", "cover_id": 2067493, "first_chap_id": 96238, "cover_url": "https://i.motiezw.com/cover/1148/2067493.jpg"}], "chapters": [{"cid": "96124", "title": "No.001 踏上征途", "title_zh": "No.001 踏上征途"}, {"cid": "96125", "title": "No.002 風雨見人心", "title_zh": "No.002 风雨见人心"}, {"cid": "96126", "title": "No.003 最終的選擇", "title_zh": "No.003 最终的选择"}, {"cid": "96127", "title": "No.004 魔獸凶狐狸", "title_zh": "No.004 魔兽凶狐狸"}, {"cid": "96128", "title": "No.005 第一次測試開始①", "title_zh": "No.005 第一次测试开始①"}, {"cid": "96129", "title": "No.006 第一次測試開始②", "title_zh": "No.006 第一次测试开始②"}, {"cid": "96130", "title": "No.007 各有所因", "title_zh": "No.007 各有所因"}, {"cid": "96131", "title": "No.008 四面楚歌", "title_zh": "No.008 四面楚歌"}, {"cid": "96133", "title": "No.009 霧中攻防戰", "title_zh": "No.009 雾中攻防战"}, {"cid": "96134", "title": "No.010 意外的試題", "title_zh": "No.010 意外的试题"}, {"cid": "96135", "title": "No.011 當然的結果", "title_zh": "No.011 当然的结果"}, {"cid": "96136", "title": "No.012 會長來訪", "title_zh": "No.012 会长来访"}, {"cid": "96137", "title": "No.013 深夜的遊戲①", "title_zh": "No.013 深夜的游戏①"}, {"cid": "96138", "title": "No.014 深夜的遊戲②", "title_zh": "No.014 深夜的游戏②"}, {"cid": "96139", "title": "No.015 表決之路", "title_zh": "No.015 表决之路"}, {"cid": "96140", "title": "No.016 試煉官登場", "title_zh": "No.016 试炼官登场"}, {"cid": "96141", "title": "No.017 艱難的二選一", "title_zh": "No.017 艰难的二选一"}, {"cid": "96143", "title": "No.018 最後兩張王牌", "title_zh": "No.018 最后两张王牌"}, {"cid": "96144", "title": "No.019 表決陷阱", "title_zh": "No.019 表决陷阱"}, {"cid": "96145", "title": "No.020 賭博時間", "title_zh": "No.020 赌博时间"}, {"cid": "96146", "title": "No.021 決戰", "title_zh": "No.021 决战"}, {"cid": "96148", "title": "No.023 兩人之敵", "title_zh": "No.023 两人之敌"}, {"cid": "96149", "title": "No.024 特訓", "title_zh": "No.024 特训"}, {"cid": "96150", "title": "No.025 第二天", "title_zh": "No.025 第二天"}, {"cid": "96151", "title": "No.026 決戰前夜", "title_zh": "No.026 决战前夜"}, {"cid": "96153", "title": "No.027 一觸即發", "title_zh": "No.027 一触即发"}, {"cid": "96154", "title": "No.028 “人Q”巨債", "title_zh": "No.028 “人Q”巨债"}, {"cid": "96155", "title": "No.029 奇犽的處境", "title_zh": "No.029 奇犽的处境"}, {"cid": "96156", "title": "No.030 蠕動的陷阱", "title_zh": "No.030 蠕动的陷阱"}, {"cid": "96157", "title": "No.031 死裡逃生", "title_zh": "No.031 死里逃生"}, {"cid": "96158", "title": "No.032 最後的測試", "title_zh": "No.032 最后的测试"}, {"cid": "96159", "title": "No.033 最後的測試開始!", "title_zh": "No.033 最后的测试开始!"}, {"cid": "96160", "title": "No.034 第一位合格者!", "title_zh": "No.034 第一位合格者!"}, {"cid": "96161", "title": "No.035 光與影①", "title_zh": "No.035 光与影①"}, {"cid": "96163", "title": "No.036 光與影②", "title_zh": "No.036 光与影②"}, {"cid": "96164", "title": "No.037 光與影③", "title_zh": "No.037 光与影③"}, {"cid": "96165", "title": "No.038 金·富力士", "title_zh": "No.038 金·富力士"}, {"cid": "96166", "title": "No.039 入侵者", "title_zh": "No.039 入侵者"}, {"cid": "96167", "title": "No.040 揍敵客家族 ①", "title_zh": "No.040 揍敌客家族 ①"}, {"cid": "96168", "title": "No.041 揍敵客家族 ②", "title_zh": "No.041 揍敌客家族 ②"}, {"cid": "96169", "title": "No.042 揍敵客家族 ③", "title_zh": "No.042 揍敌客家族 ③"}, {"cid": "96170", "title": "No.043 揍敵客家族 ④", "title_zh": "No.043 揍敌客家族 ④"}, {"cid": "96171", "title": "No.044 天空競技場", "title_zh": "No.044 天空竞技场"}, {"cid": "96173", "title": "No.045 煉", "title_zh": "No.045 炼"}, {"cid": "96174", "title": "No.046 念", "title_zh": "No.046 念"}, {"cid": "96175", "title": "No.047 看不見的牆壁", "title_zh": "No.047 看不见的墙壁"}, {"cid": "96176", "title": "No.048 西索的條件", "title_zh": "No.048 西索的条件"}, {"cid": "96177", "title": "No.049 戰鬥開始!", "title_zh": "No.049 战斗开始!"}, {"cid": "96178", "title": "No.050 絕", "title_zh": "No.050 绝"}, {"cid": "96179", "title": "No.051 點", "title_zh": "No.051 点"}, {"cid": "96180", "title": "No.052 華石鬥郎", "title_zh": "No.052 华石斗郎"}, {"cid": "96181", "title": "No.053 分身", "title_zh": "No.053 分身"}, {"cid": "96182", "title": "No.054 敗因", "title_zh": "No.054 败因"}, {"cid": "96184", "title": "No.055 西索是⋯⋯", "title_zh": "No.055 西索是⋯⋯"}, {"cid": "96185", "title": "No.056 再次修行", "title_zh": "No.056 再次修行"}, {"cid": "96186", "title": "No.057 約定", "title_zh": "No.057 约定"}, {"cid": "96187", "title": "No.058 再戰", "title_zh": "No.058 再战"}, {"cid": "96188", "title": "No.059 過關", "title_zh": "No.059 过关"}, {"cid": "96189", "title": "No.060 合格", "title_zh": "No.060 合格"}, {"cid": "96190", "title": "No.061 決戰", "title_zh": "No.061 决战"}]};
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>