// ==UserScript== // @name VIP解析在线工具 // @namespace http://tampermonkey.net/ // @version 1.0 // @description VIP视频解析在线工具箱,集成多个备用解析网站,一键跳转,让解析更简单 // @author You // @match *://*/* // @grant GM_setClipboard // @grant GM_addStyle // @grant GM_getValue // @grant GM_setValue // @run-at document-idle // @license MIT // ==/UserScript== (function() { 'use strict'; // ==================== 配置 ==================== const CONFIG = { // 在线解析网站列表 parseSites: [ { name: '全民解析', url: 'https://jx.kuzibang.com/', desc: '支持18个平台,15条线路', color: '#e74c3c' }, { name: 'M1907云加速', url: 'https://m1907.top/', desc: '高速稳定,支持多种格式', color: '#3498db' }, { name: 'OK解析', url: 'https://okjx.cc/', desc: '老牌稳定解析', color: '#9b59b6' }, { name: '虾米解析', url: 'https://jx.xmflv.com/', desc: '简洁高效', color: '#f39c12' }, { name: '夜幕影视', url: 'https://www.yemu.xyz/', desc: '高清流畅', color: '#1abc9c' }, { name: 'CKMOV', url: 'https://www.ckmov.com/', desc: '支持多平台', color: '#e67e22' }, { name: '诺讯解析', url: 'https://www.nxunxiao.com/', desc: '稳定可靠', color: '#2ecc71' }, { name: 'M3U8TV', url: 'https://jx.m3u8.tv/', desc: '专业M3U8解析', color: '#00a8ff' } ], // 快捷视频网站(获取视频链接用) videoSites: [ { name: '腾讯视频', url: 'https://v.qq.com/', icon: '🦊' }, { name: '爱奇艺', url: 'https://www.iqiyi.com/', icon: '🥝' }, { name: '优酷', url: 'https://www.youku.com/', icon: '👖' }, { name: '芒果TV', url: 'https://www.mgtv.com/', icon: '🥭' }, { name: '哔哩哔哩', url: 'https://www.bilibili.com/', icon: '📺' } ], popupWidth: 500, popupHeight: 600 }; // ==================== 样式 ==================== const STYLES = ` /* 悬浮按钮 */ .vip-online-btn { position: fixed; bottom: 100px; right: 20px; z-index: 999999; display: flex; align-items: center; justify-content: center; width: 60px; height: 60px; background: linear-gradient(135deg, #667eea 0%, #764ba2 100%); border: none; border-radius: 50%; color: #fff; font-size: 24px; cursor: pointer; box-shadow: 0 4px 20px rgba(102, 126, 234, 0.5); transition: all 0.3s ease; } .vip-online-btn:hover { transform: scale(1.1); box-shadow: 0 6px 30px rgba(102, 126, 234, 0.7); } .vip-online-btn::before { content: '🌐'; } /* 弹窗 */ .vip-online-modal { position: fixed; top: 50%; left: 50%; transform: translate(-50%, -50%); width: ${CONFIG.popupWidth}px; max-width: 95vw; height: ${CONFIG.popupHeight}px; max-height: 90vh; background: linear-gradient(145deg, #1a1a2e 0%, #16213e 100%); border-radius: 20px; box-shadow: 0 25px 80px rgba(0, 0, 0, 0.6); z-index: 9999999; display: none; flex-direction: column; overflow: hidden; } .vip-online-modal.show { display: flex; } /* 遮罩 */ .vip-online-overlay { position: fixed; top: 0; left: 0; width: 100%; height: 100%; background: rgba(0, 0, 0, 0.7); z-index: 9999998; display: none; } .vip-online-overlay.show { display: block; } /* 头部 */ .vip-online-header { padding: 20px; background: rgba(255, 255, 255, 0.05); border-bottom: 1px solid rgba(255, 255, 255, 0.1); display: flex; justify-content: space-between; align-items: center; } .vip-online-title { font-size: 18px; font-weight: bold; color: #fff; display: flex; align-items: center; gap: 10px; } .vip-online-close { width: 36px; height: 36px; border: none; background: rgba(255, 255, 255, 0.1); color: #fff; font-size: 20px; border-radius: 50%; cursor: pointer; transition: all 0.3s; } .vip-online-close:hover { background: rgba(231, 76, 60, 0.8); transform: rotate(90deg); } /* 内容区 */ .vip-online-body { flex: 1; padding: 20px; overflow-y: auto; } /* 提示框 */ .vip-online-tip { background: rgba(255, 165, 0, 0.15); border: 1px solid rgba(255, 165, 0, 0.3); border-radius: 10px; padding: 15px; margin-bottom: 20px; } .vip-online-tip h4 { color: #ffa500; margin-bottom: 10px; font-size: 14px; } .vip-online-tip ol { padding-left: 20px; color: #ccc; font-size: 13px; } .vip-online-tip li { padding: 4px 0; } /* 快捷入口 */ .vip-online-sites { margin-bottom: 20px; } .vip-online-sites h3 { color: #00d9ff; margin-bottom: 12px; font-size: 14px; } .vip-online-sites-grid { display: flex; flex-wrap: wrap; gap: 8px; } .vip-online-site-btn { padding: 8px 15px; background: rgba(255, 255, 255, 0.08); border: 1px solid rgba(255, 255, 255, 0.15); border-radius: 20px; color: #fff; font-size: 13px; cursor: pointer; transition: all 0.3s; text-decoration: none; } .vip-online-site-btn:hover { background: rgba(0, 217, 255, 0.2); border-color: #00d9ff; } /* 解析网站列表 */ .vip-online-parsers { margin-bottom: 20px; } .vip-online-parsers h3 { color: #00ff88; margin-bottom: 12px; font-size: 14px; } .vip-online-parser-card { background: rgba(255, 255, 255, 0.05); border: 1px solid rgba(255, 255, 255, 0.1); border-radius: 12px; padding: 15px; margin-bottom: 10px; transition: all 0.3s; } .vip-online-parser-card:hover { border-color: var(--site-color, #00d9ff); transform: translateX(5px); } .vip-online-parser-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 8px; } .vip-online-parser-name { font-size: 16px; font-weight: bold; color: #fff; } .vip-online-parser-link { display: inline-block; padding: 8px 20px; background: linear-gradient(135deg, var(--site-color, #00d9ff) 0%, var(--site-color2, #00ff88) 100%); color: #000; text-decoration: none; border-radius: 20px; font-size: 13px; font-weight: bold; transition: all 0.3s; } .vip-online-parser-link:hover { transform: translateY(-2px); box-shadow: 0 5px 15px rgba(0, 217, 255, 0.4); } .vip-online-parser-desc { font-size: 13px; color: #888; } /* 底部说明 */ .vip-online-footer { padding: 15px 20px; background: rgba(0, 0, 0, 0.2); border-top: 1px solid rgba(255, 255, 255, 0.05); text-align: center; } .vip-online-footer p { color: #666; font-size: 12px; } /* 滚动条 */ .vip-online-body::-webkit-scrollbar { width: 6px; } .vip-online-body::-webkit-scrollbar-track { background: rgba(255, 255, 255, 0.05); } .vip-online-body::-webkit-scrollbar-thumb { background: rgba(255, 255, 255, 0.2); border-radius: 3px; } .vip-online-body::-webkit-scrollbar-thumb:hover { background: rgba(255, 255, 255, 0.3); } `; // ==================== 工具函数 ==================== // 显示提示 function showToast(msg) { const existing = document.querySelector('.vip-online-toast'); if (existing) existing.remove(); const toast = document.createElement('div'); toast.className = 'vip-online-toast'; toast.textContent = msg; toast.style.cssText = ` position: fixed; bottom: 180px; right: 25px; padding: 12px 25px; background: rgba(0, 0, 0, 0.9); color: #fff; border-radius: 25px; font-size: 14px; z-index: 10000000; animation: vipOnlineFadeIn 0.3s ease; `; const style = document.createElement('style'); style.textContent = ` @keyframes vipOnlineFadeIn { from { opacity: 0; transform: translateY(20px); } to { opacity: 1; transform: translateY(0); } } `; document.head.appendChild(style); document.body.appendChild(toast); setTimeout(() => toast.remove(), 2500); } // 获取颜色数组 function getColorPair(index) { const colors = [ ['#e74c3c', '#c0392b'], ['#3498db', '#2980b9'], ['#9b59b6', '#8e44ad'], ['#f39c12', '#e67e22'], ['#1abc9c', '#16a085'], ['#e67e22', '#d35400'], ['#2ecc71', '#27ae60'], ['#00a8ff', '#0088cc'] ]; return colors[index % colors.length]; } // ==================== UI 创建 ==================== // 添加样式 function addStyles() { GM_addStyle(STYLES); } // 创建悬浮按钮 function createFloatingButton() { const btn = document.createElement('button'); btn.className = 'vip-online-btn'; btn.title = 'VIP解析在线工具'; btn.addEventListener('click', () => toggleModal(true)); document.body.appendChild(btn); } // 创建模态框 function createModal() { // 遮罩 const overlay = document.createElement('div'); overlay.className = 'vip-online-overlay'; overlay.addEventListener('click', () => toggleModal(false)); document.body.appendChild(overlay); // 模态框 const modal = document.createElement('div'); modal.className = 'vip-online-modal'; modal.id = 'vipOnlineModal'; modal.innerHTML = `