├── .gitignore ├── .idea ├── .gitignore ├── hikerViewRules.iml ├── misc.xml ├── modules.xml └── vcs.xml ├── COLLECTION ├── assets.js ├── gcores.js ├── gods_plan.js └── nga │ ├── bbcode2Html.js │ └── nga.js ├── COMIC ├── hentai-one.js ├── maofly.js ├── mh3618.js └── picacg.js ├── GHS ├── 3dhentai.js ├── 7719.js ├── JavTree.js ├── JavWan.js ├── MissAV.js ├── eporner.js ├── eroticmovies.xyz.js ├── hxc.js ├── jable.js ├── ohentai.js ├── pornhub.js ├── shuiguopai.js ├── spankbang.js └── yande.re.js ├── God_Plan.js ├── HOME └── index.html ├── IMAGE ├── ChilloutMix.js ├── Hentai Cosplay.js ├── artstation.js ├── cos.js ├── huashi6.js ├── iconfont.js └── zcool.js ├── LIVE ├── 17live.js ├── 95_xiu.js ├── AfreecaTV.js ├── collection │ ├── index.js │ └── pages │ │ └── douyu.js ├── douyu.js ├── douyu_danmu.js ├── huya.js ├── qie_egame.js ├── qie_sport.js └── twitch.js ├── README.md ├── TEST ├── acfun-bangumilist.js ├── new-homepage.js ├── x5.js └── youtube.js ├── TEXT └── juejin.js ├── TOOL ├── aktools.js ├── bailan_paste.js ├── baota.js ├── bt.js ├── cloud-music.js ├── naraka_score.js ├── prts.js ├── ys_map.js └── zczc.js ├── VIDEO ├── 400.js ├── 4kvm.js ├── 555dy.js ├── OneList.js ├── buosn.js ├── douyin │ ├── douyin_web.js │ └── signature.js ├── douyin_slide.js ├── douyin_web.js ├── ednovas.js ├── histar.js ├── simple_douyin_web.js ├── xiletv.js └── youtube.js ├── assets ├── icons │ ├── list.png │ ├── ps4.svg │ ├── search.png │ ├── setting.png │ ├── sort-ascending.png │ ├── sort-descending.png │ ├── steam.svg │ ├── switch.svg │ ├── turn.png │ ├── xboxone.svg │ ├── 专题.svg │ ├── 关注.svg │ ├── 播单.svg │ ├── 收藏.svg │ ├── 文章.svg │ ├── 游戏.svg │ ├── 电台.svg │ ├── 视频.svg │ ├── 设置.svg │ └── 资讯.svg └── images │ ├── 4k.png │ ├── avatar-r.png │ ├── avatar.jpg │ ├── chuzhan.png │ ├── douyin.jpg │ ├── douyu.png │ ├── github.svg │ ├── huya.png │ ├── juejin.png │ ├── nga.png │ ├── pica.jpg │ ├── qie_e.png │ ├── twitch.png │ ├── youtube.png │ └── zcool.jpg ├── data ├── base.json ├── music_list.json ├── nsfw.json └── rules.json ├── public ├── CloudMusic.html ├── CloudMusic │ └── tabs.html ├── Home.html ├── banner.html ├── category.html ├── css │ ├── aliplayer-min.css │ ├── douyu_danmu.css │ ├── element-ui.css │ └── vant.css ├── douyu-danmu-tabs.html ├── douyu-player.html ├── douyu-tabs.html ├── douyu_danmu.html ├── fonts │ └── AlexBrush-Regular.ttf ├── gcores_banners.html ├── huya-category.html ├── huya-player.html ├── huya-tabs.html ├── js │ ├── aliplayer-min.js │ ├── douyu_danmu.js │ ├── element-ui.js │ ├── vant.min.js │ └── vue.min.js ├── markdown.html ├── mix-manifest.json ├── netEasy-music-master │ ├── .gitignore │ ├── README.md │ ├── css │ │ ├── home.css │ │ ├── playlist.css │ │ ├── reset.css │ │ └── song.css │ ├── home.html │ ├── js │ │ ├── av.js │ │ ├── device.js │ │ ├── leanCloud.js │ │ ├── playlist.js │ │ ├── song.js │ │ └── tab.js │ ├── package-lock.json │ ├── package.json │ ├── playlist.html │ ├── song.html │ ├── vendors │ │ ├── av-min.js │ │ ├── jquery.min.js │ │ └── loaders.min.css │ └── yarn.lock ├── new_home.html ├── qieEgame-tabs.html └── utils │ └── huya_lib.js └── tyrantgenesis.js /.gitignore: -------------------------------------------------------------------------------- 1 | .DS_Store 2 | /node_modules 3 | /dist 4 | 5 | 6 | # local env files 7 | .env.local 8 | .env.*.local 9 | 10 | # Log files 11 | npm-debug.log* 12 | yarn-debug.log* 13 | yarn-error.log* 14 | pnpm-debug.log* 15 | 16 | # Editor directories and files 17 | .idea 18 | .vscode 19 | *.suo 20 | *.ntvs* 21 | *.njsproj 22 | *.sln 23 | *.sw? 24 | -------------------------------------------------------------------------------- /.idea/.gitignore: -------------------------------------------------------------------------------- 1 | # Default ignored files 2 | /shelf/ 3 | /workspace.xml 4 | # 基于编辑器的 HTTP 客户端请求 5 | /httpRequests/ 6 | -------------------------------------------------------------------------------- /.idea/hikerViewRules.iml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /.idea/misc.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 6 | -------------------------------------------------------------------------------- /.idea/modules.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /.idea/vcs.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /COLLECTION/assets.js: -------------------------------------------------------------------------------- 1 | const BASE_URL = "https://git.tyrantg.com/tyrantgenesis/hikerViewRules/raw/master/assets/" 2 | const LOCAL_URL = 'hiker://files/rules/TyrantG/assets/' 3 | 4 | const godSaveFile = (asset_path) => { 5 | saveImage(BASE_URL+asset_path, LOCAL_URL+asset_path) 6 | } 7 | 8 | godSaveFile('images/avatar.jpg') -------------------------------------------------------------------------------- /COLLECTION/gods_plan.js: -------------------------------------------------------------------------------- 1 | // const LOCAL_ASSETS = 'hiker://files/rules/TyrantG/assets.js' 2 | const FETCH_FILE = 'https://git.tyrantg.com/tyrantgenesis/hikerViewRules/raw/master/COLLECTION/gods_plan.js' 3 | const VERSION_FILE = 'https://git.tyrantg.com/tyrantgenesis/hikerViewRules/raw/master/data/version' 4 | 5 | const VERSION = '1.0.0-beta' 6 | 7 | const baseParse = _ => { 8 | let d = [], syncTitle = "God's Plan 当前版本:"+VERSION 9 | 10 | if (VERSION !== request(VERSION_FILE)) { 11 | syncTitle = "God's Plan可更新 - 最新版本: "+request(VERSION_FILE) 12 | } 13 | 14 | d.push({ 15 | title: syncTitle, 16 | pic_url: "https://git.tyrantg.com/tyrantgenesis/hikerViewRules/raw/master/assets/images/avatar.jpg", 17 | url: $().lazyRule(_ => { 18 | const LOCAL_FILE = 'hiker://files/rules/TyrantG/gods_plan.js' 19 | const FETCH_FILE = 'https://git.tyrantg.com/tyrantgenesis/hikerViewRules/raw/master/COLLECTION/gods_plan.js' 20 | // const FETCH_ASSETS = 'https://git.tyrantg.com/tyrantgenesis/hikerViewRules/raw/master/COLLECTION/assets.js' 21 | writeFile(LOCAL_FILE, request(FETCH_FILE)) 22 | // eval(request(FETCH_ASSETS)) 23 | refreshPage(false) 24 | return "hiker://empty" 25 | }), 26 | col_type: 'text_1' 27 | }) 28 | 29 | d.push({ 30 | col_type: 'input' 31 | }) 32 | 33 | setResult(d); 34 | } 35 | -------------------------------------------------------------------------------- /COLLECTION/nga/bbcode2Html.js: -------------------------------------------------------------------------------- 1 | const nodes = [ 2 | // 基本字体样式 3 | { 4 | tag: "b", 5 | html_open: "", 6 | html_close: "" 7 | }, 8 | { 9 | tag: "i", 10 | html_open: "", 11 | html_close: "" 12 | }, 13 | { 14 | tag: "del", 15 | html_open: "", 16 | html_close: "" 17 | }, 18 | { 19 | tag: "u", 20 | html_open: "", 21 | html_close: "" 22 | }, 23 | { 24 | tag: "color", 25 | html_open: attr => ``, 26 | html_close: "" 27 | }, 28 | { 29 | tag: "size", 30 | html_open: attr => ``, 31 | html_close: "" 32 | }, 33 | 34 | // 折叠 35 | { 36 | tag: "collapse", 37 | html_open: attr => `
${attr || '折叠内容'}`, 38 | html_close: "
" 39 | }, 40 | 41 | // 引用 42 | { 43 | tag: "quote", 44 | html_open: "
", 45 | html_close: "
" 46 | }, 47 | 48 | // 列表 49 | { 50 | tag: "list", 51 | html_open: "" 53 | }, 54 | { 55 | tag: "*", 56 | html_open: "
  • ", 57 | html_close: "
  • " 58 | }, 59 | 60 | // 分割线 61 | { 62 | tag: "h", 63 | html_open: attr => `${attr ? '' + attr + '' : ''}
    `, 64 | html_close: "" 65 | }, 66 | 67 | // 注解 68 | // { 69 | // tag: "dict", 70 | // html_open: attr => { 71 | // 72 | // return `` 73 | // }, 74 | // html_close: "" 75 | // }, 76 | 77 | // 链接 78 | { 79 | tag: "url", 80 | html_open: attr => `[`, 81 | html_close: "]" 82 | }, 83 | 84 | 85 | 86 | 87 | 88 | 89 | 90 | 91 | 92 | 93 | 94 | 95 | 96 | 97 | 98 | 99 | 100 | 101 | 102 | 103 | 104 | { 105 | tag: "uid", 106 | html_open: "", 107 | html_close: "" 108 | }, 109 | { 110 | tag: "pid", 111 | html_open: "", 112 | html_close: "" 113 | }, 114 | { 115 | tag: "tid", 116 | html_open: "", 117 | html_close: "" 118 | }, 119 | { 120 | tag: "h1", 121 | html_open: "

    ", 122 | html_close: "

    " 123 | }, 124 | { 125 | tag: "h2", 126 | html_open: "

    ", 127 | html_close: "

    " 128 | }, 129 | { 130 | tag: "h3", 131 | html_open: "

    ", 132 | html_close: "

    " 133 | }, 134 | { 135 | tag: "h4", 136 | html_open: "

    ", 137 | html_close: "

    " 138 | }, 139 | { 140 | tag: "h5", 141 | html_open: "
    ", 142 | html_close: "
    " 143 | }, 144 | { 145 | tag: "h6", 146 | html_open: "
    ", 147 | html_close: "
    " 148 | }, 149 | { 150 | tag: "center", 151 | html_open: ``, 152 | html_close: "" 153 | }, 154 | { 155 | tag: "list", 156 | html_open: "" 158 | }, 159 | { 160 | tag: "olist", 161 | html_open: "
      ", 162 | html_close: "
    " 163 | }, 164 | { 165 | tag: "*", 166 | html_open: "
  • ", 167 | html_close: "
  • " 168 | }, 169 | { 170 | tag: "img", 171 | html_open: attr => `${attr || `, 172 | html_close: "" 173 | }, 174 | { 175 | tag: "quote", 176 | html_open: '', 177 | html_close: "

    " 178 | }, 179 | ]; 180 | 181 | function get(tag) { 182 | return nodes.find(node => node.tag === tag); 183 | } 184 | 185 | function parser(str) { 186 | if (!str) { 187 | throw "Parse string is empty"; 188 | } 189 | 190 | let html = str.slice(0); 191 | 192 | const tags = str.match(/(\[[^\]^\s]{1,}\])/g); 193 | 194 | if (!tags || tags.length < 1) 195 | return html; 196 | 197 | let args; 198 | let closing; 199 | let name; 200 | let node; 201 | let attr; 202 | let open; 203 | tags.forEach(tag => { 204 | args = tag.slice(1, -1).split("="); 205 | closing = args[0].startsWith("/"); 206 | name = closing ? args[0].slice(1) : args[0]; 207 | attr = args[1]; 208 | 209 | node = get(name); 210 | 211 | if (node) { 212 | open = typeof (node.html_open) === "function" ? node.html_open(attr) : node.html_open; 213 | html = html.replace(tag, closing ? node.html_close : open); 214 | } 215 | }); 216 | 217 | return html.replace(/(?:\r\n|\r|\n)/g, "

    "); 218 | } 219 | 220 | $.exports = { 221 | parser: parser, 222 | } 223 | -------------------------------------------------------------------------------- /COMIC/hentai-one.js: -------------------------------------------------------------------------------- 1 | const one = { 2 | empty: 'hiker://empty', 3 | d: [], 4 | data: { 5 | subTab: getMyVar('HentaiOne.subTab', '0'), 6 | }, 7 | baseParse: () => { 8 | const [url, page] = MY_URL.split('##') 9 | one.list(pdfa(fetch(url+'/?page='+page), '.gallery-list&&a')) 10 | setResult(one.d) 11 | }, 12 | searchParse: () => { 13 | one.list(pdfa(getResCode(), '#list&&a')) 14 | setResult(one.d) 15 | }, 16 | list: (list) => { 17 | list.forEach(item => { 18 | let title = pdfh(item, '.gallery-item-ttl&&Text') 19 | let url = pd(item, 'a&&href') 20 | let pic_url = pdfh(item, 'img&&src') 21 | one.d.push({ 22 | title: title, 23 | url: $(url+'#immersiveTheme#').rule((title, url, pic_url) => { 24 | const one = $.require('hiker://page/one') 25 | one.detail(title, url, pic_url) 26 | setResult(one.d) 27 | }, title, url, pic_url), 28 | pic_url: pic_url, 29 | col_type: 'movie_3', 30 | }) 31 | }) 32 | }, 33 | detail: (title, url, pic_url) => { 34 | setPageTitle(title) 35 | const html = getResCode() 36 | one.d.push({ 37 | title: title, 38 | url: url, 39 | pic_url: pic_url, 40 | col_type: 'movie_1_vertical_pic_blur', 41 | }) 42 | one.d.push({ 43 | col_type: 'line_blank' 44 | }) 45 | 46 | const tags = pdfa(html, '.detail-infos&&.detail-tags,4&&a') 47 | 48 | tags.forEach(tag => { 49 | let title = pdfh(tag, 'a&&Text') 50 | let url = pd(tag, 'a&&href') 51 | one.d.push({ 52 | title: pdfh(tag, 'a&&Text'), 53 | url: $(url+'?page=fypage').rule((title) => { 54 | const one = $.require('hiker://page/one') 55 | one.tag(title) 56 | setResult(one.d) 57 | }, title), 58 | col_type: 'flex_button', 59 | }) 60 | }) 61 | 62 | one.d.push({ 63 | col_type: 'line_blank' 64 | }) 65 | 66 | const desc_url = pd(html, '.detail-link-row&&a&&href') 67 | 68 | one.d.push({ 69 | title: '浏览', 70 | url: one.getPics(desc_url), 71 | col_type: 'text_center_1', 72 | }) 73 | one.d.push({ 74 | col_type: 'line_blank' 75 | }) 76 | 77 | one.d.push({ 78 | title: '相似内容', 79 | url: one.empty, 80 | col_type: 'text_1', 81 | }) 82 | 83 | one.list(pdfa(html, '.gallery-list&&a')) 84 | }, 85 | tag: (title) => { 86 | setPageTitle(title) 87 | try { 88 | one.list(pdfa(getResCode(), '.gallery-list&&a')) 89 | } catch(e) {} 90 | }, 91 | getPics: (url) => { 92 | const img_list = [] 93 | const html = fetch(url) 94 | const match = html.match(/\\"src\\":\\"(.*?)\\"/g) 95 | match.forEach(img => { 96 | img_list.push(img.replace(/\\"src\\":\\"(.*?)\\"/, "$1")) 97 | }) 98 | return 'pics://'+img_list.join('&&') 99 | }, 100 | } 101 | 102 | $.exports = one 103 | -------------------------------------------------------------------------------- /COMIC/mh3618.js: -------------------------------------------------------------------------------- 1 | const baseParse = _ => { 2 | const d = [] 3 | const list = pdfa(getResCode(), '.books&&.bk') 4 | const class_url = MY_RULE.class_url 5 | 6 | list.forEach(item => { 7 | let url 8 | if (class_url === 'dpxs/list_3' || class_url === 'cpxs/list_2') { 9 | url = $(pd(item, 'a&&href')).rule(() => { 10 | const d = [] 11 | const list = pdfa(getResCode(), 'ul,1&&li') 12 | 13 | list.forEach(item => { 14 | d.push({ 15 | title: pdfh(item, 'a&&Text'), 16 | col_type: 'text_1', 17 | url: $(pd(item, 'a&&href')+'#readTheme#').rule(() => { 18 | const d = [] 19 | d.push({ 20 | title: pdfh(getResCode(), '#contxt&&Text'), 21 | col_type: 'rich_text', 22 | extra: { 23 | click: true, 24 | } 25 | }) 26 | setResult(d); 27 | }), 28 | }) 29 | }) 30 | 31 | setResult(d); 32 | }) 33 | } else { 34 | url = $(pd(item, 'a&&href')).lazyRule(() => { 35 | const img_list = [] 36 | const list = pdfa(fetch(input), 'ul,1&&li') 37 | list.forEach(item => { 38 | let true_page = pd(item, 'a&&href') 39 | let img_array = pdfa(fetch(true_page), '#htmlContent&&img') 40 | img_array.forEach(img => { 41 | img_list.push(pdfh(img, 'img&&src')) 42 | }) 43 | }) 44 | return 'pics://'+img_list.join('&&') 45 | }) 46 | } 47 | d.push({ 48 | title: pdfh(item, 'h3&&Text'), 49 | pic_url: pd(item, '.pic&&img&&src'), 50 | desc: pdfh(item, 'span&&Text'), 51 | url: url, 52 | }) 53 | }) 54 | 55 | setResult(d); 56 | } 57 | -------------------------------------------------------------------------------- /GHS/3dhentai.js: -------------------------------------------------------------------------------- 1 | const ht = { 2 | empty: 'hiker://empty', 3 | url: 'https://3dhentai.co', 4 | d: [], 5 | lazyRule: true, 6 | taskList: [], 7 | data: { 8 | category: getMyVar('3dhentai.category', '0'), 9 | }, 10 | baseParse: () => { 11 | const page = parseInt(MY_URL.split('##')[1]) 12 | 13 | let categoryList = [{type: 'Home', path: ''}, {type: 'Tags', path: '/tag'}, {type: 'Artists', path: '/artist'}, {type: 'Characters', path: '/characters'}] 14 | const currentCate = categoryList[ht.data.category] 15 | 16 | const type = currentCate.type 17 | const path = currentCate.path 18 | let url = ht.url + path 19 | 20 | if (type !== 'Artists') { 21 | url += '/page/'+page 22 | } 23 | 24 | if (page === 1) { 25 | categoryList.forEach((cate, index) => { 26 | ht.d.push({ 27 | title: parseInt(ht.data.category) === index ? '‘‘’’'+cate.type+'' : cate.type, 28 | url: $(ht.empty).lazyRule((index) => { 29 | putMyVar("3dhentai.category", index.toString()) 30 | refreshPage(true) 31 | return "hiker://empty" 32 | }, index), 33 | col_type: 'scroll_button', 34 | }) 35 | }) 36 | } 37 | 38 | const html = fetch(url) 39 | 40 | ht.videoType(html, type) 41 | 42 | setResult(ht.d) 43 | }, 44 | searchParse: () => { 45 | ht.videoType(getResCode(), 'Home') 46 | setResult(ht.d) 47 | }, 48 | videoParse: (url) => { 49 | const html = fetch(url) 50 | const title = pdfh(html, 'h1&&Text') 51 | setPageTitle(title) 52 | 53 | const videoFrameUrl = pdfh(html, 'iframe&&src'); 54 | const videoName = videoFrameUrl.split('&video=')[1] 55 | 56 | ht.d.push({ 57 | title: title, 58 | desc: pdfh(html, '.video-views&&Text'), 59 | pic_url: pdfh(html, 'meta[property=og:image]&&content')+'@Referer='+ht.url, 60 | url: 'https://3dhq1.org/video/3d/' + videoName, 61 | col_type: 'pic_1', 62 | }) 63 | 64 | const tagsDom1 = pdfa(html, '#video-about&&#video-actors') 65 | const tagsDom2 = pdfa(html, '#video-about&&#video-cats') 66 | const tagsDom3 = pdfa(html, '#video-about&&#video-tags') 67 | 68 | tagsDom1.concat(tagsDom2).concat(tagsDom3).forEach((item, index) => { 69 | const tags = pdfa(item, '.video-content-row&&a') 70 | 71 | ht.d.push({ 72 | title: pdfh(item, '.video-content-row&&Text').split(':')[0], 73 | url: ht.empty, 74 | col_type: 'text_center_1', 75 | extra: {lineVisible: false}, 76 | }) 77 | 78 | tags.forEach(tag => { 79 | const title = pdfh(tag, 'a&&title') 80 | ht.d.push({ 81 | title: title, 82 | url: $(pdfh(item, 'a&&href')+(index === 1 ? ('#noHistory#'+'#fypage') : '#noHistory#')).rule((tag, index) => { 83 | setPageTitle(tag) 84 | const ht = $.require('hiker://page/ht') 85 | const page = MY_PAGE 86 | if (index === 0) { 87 | ht.videoType(fetch(ht.url + '/actor/' + tag + '/page/' + page), 'Home') 88 | setResult(ht.d) 89 | } else if (index === 1) { 90 | ht.videoType(fetch(ht.url + '/artist/' + tag + '/page/' + page), 'Home') 91 | setResult(ht.d) 92 | } else { 93 | ht.videoType(fetch(ht.url + '/tag/' + tag + '/page/' + page), 'Home') 94 | setResult(ht.d) 95 | } 96 | }, title, index), 97 | col_type: 'flex_button', 98 | }) 99 | }) 100 | 101 | ht.d.push({ 102 | col_type: 'line_blank' 103 | }) 104 | }) 105 | 106 | ht.d.push({ 107 | title: 'Related Videos', 108 | url: ht.empty, 109 | col_type: 'text_center_1', 110 | }) 111 | 112 | ht.videoType(html, 'Related') 113 | }, 114 | videoType: (html, type) => { 115 | const list = type === 'Related' ? pdfa(html, '.related-videos&&.video-block') : pdfa(html, '.video-loop&&.video-block') 116 | 117 | const makeUrl = (item) => type === 'Home' && ht.lazyRule ? $(pdfh(item, 'a&&href')).lazyRule((url) => { 118 | log(url) 119 | const html = fetch(url) 120 | const videoFrameUrl = pdfh(html, 'iframe&&src'); 121 | const videoName = videoFrameUrl.split('&video=')[1] 122 | log(videoName) 123 | 124 | return 'https://3dhq1.org/video/3d/' + videoName 125 | }, pdfh(item, 'a&&href')) : $(pdfh(item, 'a&&href')+'#noHistory#').rule((type) => { 126 | const ht = $.require('hiker://page/ht') 127 | if (type === 'Home' || type === 'Related') { 128 | ht.videoParse(MY_URL) 129 | setResult(ht.d) 130 | } else { 131 | const html = fetch(MY_URL) 132 | ht.videoType(html, 'Home') 133 | setResult(ht.d) 134 | } 135 | }, type) 136 | 137 | list.forEach(item => { 138 | ht.d.push({ 139 | title: pdfh(item, '.title&&Text'), 140 | url: makeUrl(item), 141 | pic_url: pdfh(item, '.video-img&&data-src')+'@Referer='+ht.url, 142 | desc: pdfh(item, '.duration&&Text'), 143 | col_type: 'movie_2' 144 | }) 145 | }) 146 | }, 147 | } 148 | 149 | $.exports = ht 150 | -------------------------------------------------------------------------------- /GHS/7719.js: -------------------------------------------------------------------------------- 1 | const baseParse = _ => { 2 | let d = []; 3 | const list = parseDomForArray(getResCode(), '.content&&.grid_item'); 4 | for (let j in list) { 5 | d.push({ 6 | title: parseDomForHtml(list[j], '.description&&Text'), 7 | desc: parseDomForHtml(list[j], '.num&&Text'), 8 | pic_url: parseDom(list[j], 'img&&src'), 9 | url: $(parseDom(list[j],'a&&href')).lazyRule(_ => { 10 | const html = fetch(input) 11 | const script = parseDomForHtml(html, '.bofang_box&&script&&Html') 12 | eval(script) 13 | return player_data.url 14 | }) 15 | }) 16 | } 17 | 18 | setResult(d); 19 | } -------------------------------------------------------------------------------- /GHS/JavTree.js: -------------------------------------------------------------------------------- 1 | const baseParse = _ => { 2 | let d = []; 3 | const [empty, page] = MY_URL.split('##') 4 | 5 | const className = getMyVar('JavTree.tyrantgenesis.className', 'last') 6 | let url = getMyVar('JavTree.tyrantgenesis.url', 'https://javtree.com/last.html') 7 | url = url.replace('.html', '-'+page+'.html') 8 | 9 | if (parseInt(page) === 1) { 10 | d.push( 11 | { 12 | title: className === 'last' ? '““””最新更新' : '最新更新', 13 | url: $(empty).lazyRule(() => { 14 | putMyVar('JavTree.tyrantgenesis.className', 'last') 15 | putMyVar('JavTree.tyrantgenesis.url', 'https://javtree.com/last.html') 16 | refreshPage(true) 17 | return "hiker://empty" 18 | }), 19 | col_type: 'scroll_button', 20 | }, 21 | { 22 | title: className === 'category' ? '““””主題選片' : '主題選片', 23 | url: $(empty).lazyRule(() => { 24 | putMyVar('JavTree.tyrantgenesis.className', 'category') 25 | putMyVar('JavTree.tyrantgenesis.url', 'https://javtree.com/last.html') 26 | refreshPage(false) 27 | return "hiker://empty" 28 | }), 29 | col_type: 'scroll_button', 30 | }, 31 | { 32 | col_type:"blank_block" 33 | }, 34 | ) 35 | 36 | if (className === 'category') { 37 | const tags_html = fetch('https://javtree.com/tags.html') 38 | const tags = pdfa(tags_html, '.gm-main&&.gm-genre') 39 | tags.forEach(tag => { 40 | let list = pdfa(tag, '.list&&li') 41 | d.push({ 42 | title: pdfh(tag, '.title&&Text')+':', 43 | url: empty, 44 | col_type: 'scroll_button', 45 | }) 46 | list.forEach(item => { 47 | let url = 'https://javtree.com'+pdfh(item, 'a&&href') 48 | d.push({ 49 | title: pdfh(item, 'a&&Text').replace('#', ''), 50 | url: $(url).lazyRule(() => { 51 | putMyVar('JavTree.tyrantgenesis.className', 'category') 52 | putMyVar('JavTree.tyrantgenesis.url', input) 53 | refreshPage(true) 54 | return "hiker://empty" 55 | }), 56 | col_type: 'scroll_button', 57 | }) 58 | }) 59 | d.push({ 60 | col_type:"blank_block" 61 | }) 62 | }) 63 | } 64 | } 65 | 66 | const html = fetch(url) 67 | const list = pdfa(html, '.gm-list&&.item') 68 | 69 | list.forEach(item => { 70 | let pic_url = pdfh(item, 'img&&data-src') 71 | let url = 'https://javtree.com'+pdfh(item, '.title&&href') 72 | d.push({ 73 | title: pdfh(item, '.info&&.title&&Text'), 74 | desc: pdfh(item, '.volume&&Text'), 75 | pic_url: pic_url.startsWith('http') ? pic_url : 'https:'+pic_url, 76 | url: $(url).lazyRule(() => { 77 | const html = fetch(input) 78 | const video_source_json = html.match(/var post = (.*?);/)[1] 79 | const video_source = JSON.parse(video_source_json).vods 80 | 81 | return JSON.stringify({urls: video_source.map(item => item.source), names: video_source.map(item => item.name)}) 82 | }), 83 | col_type: 'movie_2', 84 | }) 85 | }) 86 | 87 | setResult(d); 88 | } 89 | -------------------------------------------------------------------------------- /GHS/JavWan.js: -------------------------------------------------------------------------------- 1 | const wan = { 2 | d: [], 3 | baseParse: () => { 4 | const html = getResCode() 5 | wan.listParse(html) 6 | setResult(wan.d) 7 | }, 8 | listParse: (html) => { 9 | const list = pdfa(html, '#main&&a') 10 | 11 | list.forEach(item => { 12 | try { 13 | let title = pdfh(item, 'a&&span&&Text') 14 | let img = pdfh(item, '.post-list-image&&img&&src') 15 | wan.d.push({ 16 | title: title, 17 | desc: pdfh(item, '.post-list-duration&&Text'), 18 | pic_url: img, 19 | url: $(pdfh(item, 'a&&href')+'#immersiveTheme#').rule((title, img) => { 20 | const wan = $.require('hiker://page/wan') 21 | wan.videoParse(title, img) 22 | setResult(wan.d) 23 | }, title, img), 24 | col_type: 'movie_2', 25 | }) 26 | }catch(e){} 27 | }) 28 | }, 29 | videoParse: (title, img) => { 30 | setPageTitle(title) 31 | const html = getResCode() 32 | const info = pdfh(html, '#post-data&&Html') 33 | 34 | let url = 'hiker://empty' 35 | const player = pdfh(info, '#player-width&&Html') 36 | const iframe = player.match(/id="iframe"/) 37 | if (iframe) { 38 | let iframe_context = '' 39 | let iframe_src = '' 40 | let script = pdfh(player, 'script&&Html').replace('return p', 'iframe_context = p') 41 | eval(script) 42 | try { 43 | iframe_src = iframe_context.match(/src="(.*?)"/)[1] 44 | }catch(e){} 45 | 46 | if (iframe_src) { 47 | url = pdfh(fetch(iframe_src), 'meta[property="og:video:url"]&&content') 48 | } 49 | } else { 50 | let context = '' 51 | let script = pdfh(player, 'script,2&&Html').replace('return p', 'context = p') 52 | eval(script) 53 | try { 54 | url = context.match(/video.src='(.*?)';/)[1] 55 | }catch(e){} 56 | } 57 | 58 | wan.d.push({ 59 | title: title, 60 | desc: pdfh(info, '.post-content&&Text'), 61 | pic_url: img, 62 | url: MY_URL, 63 | col_type: 'movie_1_vertical_pic_blur' 64 | }) 65 | 66 | wan.d.push({ 67 | col_type: 'line_blank' 68 | }) 69 | 70 | wan.d.push({ 71 | title: '播放', 72 | url: url, 73 | col_type: 'text_center_1', 74 | extra: {lineVisible: false}, 75 | }) 76 | 77 | wan.d.push({ 78 | col_type: 'line_blank' 79 | }) 80 | 81 | wan.listParse(html) 82 | }, 83 | } 84 | 85 | $.exports = wan 86 | -------------------------------------------------------------------------------- /GHS/eporner.js: -------------------------------------------------------------------------------- 1 | const baseParse = _ => { 2 | let d = []; 3 | try{ 4 | const list = parseDomForArray(getResCode(), 'body&&.mb'); 5 | for (let j in list) { 6 | d.push({ 7 | title: parseDomForHtml(list[j], '.mbtit&&Text'), 8 | desc: parseDomForHtml(list[j], '.mvhdico&&Text'), 9 | pic_url: parseDom(list[j], 'img&&src')+"@Referer=", 10 | url: parseDom(list[j],'a&&href'), 11 | }); 12 | }}catch(e){} 13 | 14 | setResult(d); 15 | } 16 | 17 | const secParse = _ => { 18 | let d = []; 19 | const list = parseDomForArray(getResCode(), 'body&&.dloaddivcol&&a'); 20 | 21 | list.forEach(item => { 22 | d.push({ 23 | title: parseDomForHtml(item, 'a&&Text').match(/\((.*?),/)[1], 24 | url: parseDom(item,'a&&href'), 25 | col_type: 'text_2', 26 | }); 27 | }) 28 | 29 | setResult(d); 30 | } -------------------------------------------------------------------------------- /GHS/eroticmovies.xyz.js: -------------------------------------------------------------------------------- 1 | const secParse = _ => { 2 | let res = {}; 3 | let d = []; 4 | const html = getResCode(); 5 | 6 | const des_title = parseDomForHtml(html, 'h1&&Text'); 7 | const des_pic = parseDom(html, 'img[title]&&src'); 8 | const des_desc = parseDomForHtml(html, '[id=fileDescription]&&Text'); 9 | 10 | const fetch_video = fetch(parseDomForHtml(html, 'iframe&&src')) 11 | 12 | const src = fetch_video.match(/src: '(.*?)',/)[1] 13 | 14 | d.push({ 15 | title: des_title, 16 | desc: des_desc, 17 | pic_url: des_pic, 18 | url: src+"#isVideo=true#", 19 | col_type: 'pic_1' 20 | }); 21 | 22 | res.data = d; 23 | setHomeResult(res); 24 | } 25 | -------------------------------------------------------------------------------- /GHS/jable.js: -------------------------------------------------------------------------------- 1 | const baseParse = _ => { 2 | let d = []; 3 | try { 4 | const list = pdfa(getResCode(), '.site-content&&.video-img-box'); 5 | for (let j in list) { 6 | d.push({ 7 | title: pdfh(list[j], 'h6&&a&&Text'), 8 | desc: pdfh(list[j], '.label&&Text'), 9 | pic_url: pd(list[j], 'img&&data-src'), 10 | url: $(pd(list[j],'a&&href')).rule(() => { 11 | eval(fetch("hiker://files/TyrantG/GHS/jable.js")) 12 | secParse() 13 | }), 14 | col_type: 'movie_2', 15 | }) 16 | } 17 | } catch (e){} 18 | 19 | setResult(d); 20 | } 21 | 22 | const secParse = _ => { 23 | let d = []; 24 | try { 25 | const html = getResCode() 26 | 27 | d.push({ 28 | title: pdfh(html, '.header-left&&h4&&Text'), 29 | desc: pdfh(html, '.video-info&&.text-center&&.tags&&Text'), 30 | pic_url: pd(html, 'video&&poster'), 31 | url: html.match(/hlsUrl = '(.*?)'/)[1], 32 | col_type: 'pic_1', 33 | }) 34 | 35 | d.push({ 36 | title: '演员', 37 | url: 'hiker://empty', 38 | col_type: 'text_center_1', 39 | extra: {lineVisible: false}, 40 | }) 41 | 42 | const models = pdfa(html, '.video-info&&.models&&a') 43 | 44 | models.forEach(model => { 45 | d.push({ 46 | title: pdfh(model, '.rounded-circle&&title'), 47 | pic_url: pdfh(model, '.rounded-circle&&src')+"@Referer=https://jable.tv/", 48 | url: $(pdfh(model, 'a&&href')).rule(() => { 49 | eval(fetch("hiker://files/TyrantG/GHS/jable.js")) 50 | baseParse() 51 | }), 52 | col_type: 'avatar', 53 | }) 54 | }) 55 | } catch (e){} 56 | 57 | setResult(d); 58 | } 59 | 60 | const makeTags = () => { 61 | const list = pdfa(getResCode(), 'nav.app-nav&&.container&&.col-6'); 62 | log(list.map(item => pdfh(item, 'a&&Text')).join('&')) 63 | log(list.map(item => pdfh(item, 'a&&href').slice(17)).join('&')) 64 | 65 | // 黑絲&過膝襪&運動裝&肉絲&絲襪&眼鏡娘&獸耳&漁網&水着&校服&旗袍&婚紗&女僕&和服&吊帶襪&兔女郎&Cosplay&黑肉&長身&軟體&貧乳&蘿莉&美腿&美尻&紋身&短髮&白虎&熟女&巨乳&少女&顏射&腳交&肛交&痙攣&潮吹&深喉&接吻&口爆&口交&乳交&中出&露出&輪姦&調教&綑綁&瞬間插入&痴漢&痴女&男M&泥醉&泡姬&母乳&放尿&按摩&強姦&多P&刑具&凌辱&一日十回&3P&黑人&醜男&誘惑&童貞&時間停止&復仇&年齡差&巨漢&媚藥&夫目前犯&出軌&催眠&偷拍&不倫&下雨天&NTR&風俗娘&醫生&逃犯&護士&老師&空姐&球隊經理&未亡人&搜查官&情侶&家政婦&家庭教師&偶像&人妻&主播&OL&魔鏡號&電車&處女&監獄&溫泉&洗浴場&泳池&汽車&廁所&學校&圖書館&健身房&便利店&錄像&處女作/引退作&綜藝&節日主題&感謝祭&4小時以上 66 | // tags/black-pantyhose/&tags/knee-socks/&tags/sportswear/&tags/flesh-toned-pantyhose/&tags/pantyhose/&tags/glasses/&tags/kemonomimi/&tags/fishnets/&tags/swimsuit/&tags/school-uniform/&tags/cheongsam/&tags/wedding-dress/&tags/maid/&tags/kimono/&tags/stockings/&tags/bunny-girl/&tags/Cosplay/&tags/suntan/&tags/tall/&tags/flexible-body/&tags/small-tits/&tags/loli/&tags/beautiful-leg/&tags/beautiful-butt/&tags/tattoo/&tags/short-hair/&tags/hairless-pussy/&tags/mature-woman/&tags/big-tits/&tags/girl/&tags/facial/&tags/footjob/&tags/anal-sex/&tags/spasms/&tags/squirting/&tags/deep-throat/&tags/kiss/&tags/cum-in-mouth/&tags/blowjob/&tags/tit-wank/&tags/creampie/&tags/outdoor/&tags/gang-rape/&tags/tune/&tags/bondage/&tags/quickie/&tags/chikan/&tags/chizyo/&tags/masochism-guy/&tags/crapulence/&tags/soapland/&tags/breast-milk/&tags/piss/&tags/massage/&tags/rape/&tags/gangbang/&tags/torture/&tags/insult/&tags/10-times-a-day/&tags/3p/&tags/black/&tags/ugly-man/&tags/temptation/&tags/virginity/&tags/time-stop/&tags/avenge/&tags/age-difference/&tags/giant/&tags/love-potion/&tags/sex-beside-husband/&tags/affair/&tags/hypnosis/&tags/hidden-cam/&tags/incest/&tags/rainy-day/&tags/ntr/&tags/club-hostess-and-sex-worker/&tags/doctor/&tags/fugitive/&tags/nurse/&tags/teacher/&tags/flight-attendant/&tags/team-manager/&tags/widow/&tags/detective/&tags/couple/&tags/housewife/&tags/private-teacher/&tags/idol/&tags/wife/&tags/female-anchor/&tags/ol/&tags/magic-mirror/&tags/tram/&tags/first-night/&tags/prison/&tags/hot-spring/&tags/bathing-place/&tags/swimming-pool/&tags/car/&tags/toilet/&tags/school/&tags/library/&tags/gym-room/&tags/store/&tags/video-recording/&tags/debut-retires/&tags/variety-show/&tags/festival/&tags/thanksgiving/&tags/more-than-4-hours/ 67 | } -------------------------------------------------------------------------------- /GHS/ohentai.js: -------------------------------------------------------------------------------- 1 | const baseParse = _ => { 2 | let d = []; 3 | try{ 4 | const list = parseDomForArray(getResCode(), '.serywrapper&&.tagtext'); 5 | for (let j in list) { 6 | d.push({ 7 | title: parseDomForHtml(list[j], '.tagtext&&Text'), 8 | url: "https://ohentai.org/"+parseDomForHtml(list[j],'a&&href').replace(/\s/g, '%20')+"&p=fypage" 9 | }); 10 | }}catch(e){} 11 | 12 | setResult(d); 13 | } 14 | 15 | const secParse = _ => { 16 | let d = []; 17 | try{ 18 | const list = parseDomForArray(getResCode(), '.videobrickwrap&&.videobrick'); 19 | 20 | for (let j in list) { 21 | let title = pdfh(list[j], '.videotitle&&Text') 22 | if (title !== 'StripChat - Live Cams') { 23 | d.push({ 24 | title: title, 25 | pic_url: "https://ohentai.org/"+pdfh(list[j], 'img&&src').replace(/\s/g, '%20'), 26 | url: $("https://ohentai.org/"+pdfh(list[j],'a&&href').replace(/\s/g, '%20')).lazyRule(_ => { 27 | const data = fetch(input).match(/sources: \[\{\"file\"\:\".*\"\}\],/) 28 | 29 | if (data) { 30 | return data[0].replace(/sources: \[\{\"file\"\:\"/, '').replace(/\"\}\],/, '') 31 | } else { 32 | return "取值失败" 33 | } 34 | }), 35 | col_type: "movie_2" 36 | }) 37 | } 38 | } 39 | }catch(e){} 40 | 41 | setResult(d); 42 | } -------------------------------------------------------------------------------- /GHS/pornhub.js: -------------------------------------------------------------------------------- 1 | const secParse = _ => { 2 | let res = {}; 3 | let d = []; 4 | const html = getResCode(); 5 | 6 | const des_title = parseDomForHtml(html, '.inlineFree&&Text'); 7 | const des_pic = parseDom(html, '#videoPlayerPlaceholder&&img&&src'); 8 | // const des_desc = parseDomForHtml(html, '.inlineFree&&Text'); 9 | const meta = parseDomForHtml(html, '[name=adsbytrafficjunkycontext]&&data-context-category'); 10 | 11 | d.push({ 12 | title: des_title, 13 | desc: meta, 14 | pic_url: des_pic, 15 | url: MY_URL, 16 | col_type: 'pic_1' 17 | }); 18 | 19 | // 这个变量定义在下面执行 script 的上方,没有被读取执行,需要手动声明避免报错 20 | let playerObjList = {} 21 | // 获取视频播放地址的变量并执行 22 | const js = parseDomForHtml(html,"[id=mobileContainer]&&script&&Html").replace(/var flashvars_.*?=/, 'var flashvars ='); 23 | eval(js); 24 | const list = flashvars.mediaDefinitions 25 | 26 | list.forEach(item => { 27 | if (typeof item.quality === 'string') { 28 | d.push({ 29 | title: item.quality, 30 | url: item.videoUrl, 31 | col_type: 'text_4' 32 | }); 33 | } 34 | }) 35 | 36 | res.data = d; 37 | setHomeResult(res); 38 | } -------------------------------------------------------------------------------- /GHS/shuiguopai.js: -------------------------------------------------------------------------------- 1 | js: 2 | let d = []; 3 | const [url, page] = MY_URL.split('##') 4 | const list_json = fetch(url, {headers: { 5 | 'Content-Type': 'application/json', 6 | 'Referer': 'https://sgpai.cc/', 7 | 'User-Agent': MOBILE_UA 8 | }, method:'POST', body: JSON.stringify({ 9 | "hm": "008-api", 10 | "length": 12, 11 | "type": 1, 12 | "page": page, 13 | })}); 14 | 15 | const list = JSON.parse(list_json).data.list 16 | 17 | if (url.includes('homePage')) { 18 | list.forEach(item => { 19 | d.push({ 20 | title: item.title, 21 | desc: item.subtitle, 22 | pic_url: item.img_url, 23 | url: $("https://sgpai.cc/play-details/1/"+item.library_id+"/").lazyRule(_ => { 24 | const html = fetch(input) 25 | return (html.match(/url:"(.*?)index.m3u8"/)[1]).replace(/\\u002F/g, '/')+"index.m3u8" 26 | }), 27 | col_type: 'movie_2' 28 | }) 29 | }) 30 | } else { 31 | list.forEach(item => { 32 | d.push({ 33 | title: item.anchors_name, 34 | desc: item.library_count+'部作品', 35 | pic_url: item.anchors_img, 36 | url: $("hiker://empty##fypage").rule(item => { 37 | let d = []; 38 | const params = { 39 | "anchors_id": item.anchors_id, 40 | "hm": "008-api", 41 | "length": 12, 42 | "page": MY_URL.split('##')[1], 43 | } 44 | const headers = { 45 | 'Content-Type': 'application/json', 46 | 'Referer': 'https://sgpai.cc/', 47 | 'User-Agent': MOBILE_UA 48 | } 49 | const data_json = fetch("https://api.cbbee0.com/v1_2/anchorsDetail", {headers: headers, method:'POST', body: JSON.stringify(params)}) 50 | const list = JSON.parse(data_json).data.list 51 | list.forEach(res => { 52 | d.push({ 53 | title: res.title, 54 | desc: res.subtitle, 55 | pic_url: res.img_url, 56 | url: $("https://sgpai.cc/play-details/1/"+res.library_id+"/").lazyRule(_ => { 57 | const html = fetch(input) 58 | return (html.match(/url:"(.*?)index.m3u8"/)[1]).replace(/\\u002F/g, '/')+"index.m3u8" 59 | }), 60 | col_type: 'movie_2' 61 | }) 62 | }) 63 | setResult(d); 64 | }, item), 65 | col_type: 'icon_round_4' 66 | }) 67 | }) 68 | } 69 | 70 | setResult(d); 71 | -------------------------------------------------------------------------------- /GHS/spankbang.js: -------------------------------------------------------------------------------- 1 | const videoSource = (stream_data, d) => { 2 | d.push({ 3 | pic_url: stream_data.cover_image, 4 | col_type: 'pic_1' 5 | }); 6 | 7 | 8 | if (stream_data['240p'].length > 0) { 9 | d.push({ 10 | title: '240p', 11 | url: stream_data['240p'][0], 12 | col_type: 'text_2' 13 | }); 14 | } 15 | if (stream_data['320p'].length > 0) { 16 | d.push({ 17 | title: '320p', 18 | url: stream_data['320p'][0], 19 | col_type: 'text_2' 20 | }); 21 | } 22 | if (stream_data['480p'].length > 0) { 23 | d.push({ 24 | title: '480p', 25 | url: stream_data['480p'][0], 26 | col_type: 'text_2' 27 | }); 28 | } 29 | if (stream_data['720p'].length > 0) { 30 | d.push({ 31 | title: '720p', 32 | url: stream_data['720p'][0], 33 | col_type: 'text_2' 34 | }); 35 | } 36 | if (stream_data['1080p'].length > 0) { 37 | d.push({ 38 | title: '1080p', 39 | url: stream_data['1080p'][0], 40 | col_type: 'text_2' 41 | }); 42 | } 43 | if (stream_data['4k'].length > 0) { 44 | d.push({ 45 | title: '4k', 46 | url: stream_data['4k'][0], 47 | col_type: 'text_2' 48 | }); 49 | } 50 | } 51 | 52 | const baseParse = _ => { 53 | let res = {}; 54 | let d = []; 55 | const html = getResCode(); 56 | 57 | const list = parseDomForArray(html, '.video-list&&.video-item'); 58 | 59 | if (Number(MY_PAGE) === 1) { 60 | d.push({ 61 | title: '分类', 62 | col_type: 'text_center_1', 63 | url: $("https://spankbang.com/categories").rule(_ => { 64 | var d = []; 65 | 66 | var list = parseDomForArray(getResCode(), '#categories&&a'); 67 | list.forEach(item => { 68 | d.push({ 69 | title: parseDomForHtml(item, 'a&&Text'), 70 | pic_url: parseDomForHtml(item, '.cover&&src'), 71 | url: $("https://spankbang.com"+parseDomForHtml(item,'a&&href').replace(/\?.*/, '')+"/fypage/").rule(_ => { 72 | let d = []; 73 | let html = getResCode(); 74 | let list = parseDomForArray(html, '.video-list&&.video-item'); 75 | 76 | list.forEach(item => { 77 | d.push({ 78 | title: parseDomForHtml(item, '.name&&Text'), 79 | desc: parseDomForHtml(item, '.l&&Text'), 80 | pic_url: parseDom(item, '.cover&&data-src'), 81 | url: $(parseDom(item,'a&&href')).rule(_ => { 82 | eval(fetch('hiker://files/TyrantG/GHS/spankbang.js')) 83 | secParse() 84 | }), 85 | col_type: 'movie_3', 86 | }); 87 | }) 88 | 89 | setResult(d) 90 | }), 91 | col_type: 'movie_3', 92 | }); 93 | }) 94 | setResult(d) 95 | }) 96 | }) 97 | } 98 | 99 | list.forEach(item => { 100 | d.push({ 101 | title: parseDomForHtml(item, '.name&&Text'), 102 | desc: parseDomForHtml(item, '.l&&Text'), 103 | pic_url: parseDom(item, '.cover&&data-src'), 104 | url: parseDom(item,'a&&href'), 105 | col_type: 'movie_3', 106 | }); 107 | }) 108 | 109 | res.data = d; 110 | setHomeResult(res); 111 | } 112 | 113 | const secParse = _ => { 114 | let res = {}; 115 | let d = []; 116 | const html = getResCode(); 117 | 118 | const script = parseDomForHtml(html, '#inner_content&&script&&Html'); 119 | eval(script) 120 | 121 | videoSource(stream_data, d) 122 | 123 | res.data = d; 124 | setHomeResult(res); 125 | } 126 | 127 | const searchParse = () => { 128 | let res = {}; 129 | let d = []; 130 | const html = getResCode(); 131 | 132 | const list = parseDomForArray(html, '.video-list&&.video-item'); 133 | list.forEach(item => { 134 | d.push({ 135 | title: parseDomForHtml(item, '.name&&Text'), 136 | desc: parseDomForHtml(item, '.l&&Text'), 137 | pic_url: parseDom(item, '.cover&&data-src'), 138 | url: parseDom(item,'a&&href'), 139 | col_type: 'movie_2', 140 | }); 141 | }) 142 | 143 | res.data = d; 144 | setHomeResult(res); 145 | } -------------------------------------------------------------------------------- /GHS/yande.re.js: -------------------------------------------------------------------------------- 1 | const baseParse = _ => { 2 | let res = {}; 3 | let d = []; 4 | const html = getResCode(); 5 | const list = parseDomForArray(html, "#post-list-posts&&li"); 6 | 7 | list.forEach(element => { 8 | d.push({ 9 | pic_url: parseDomForHtml(element, ".preview&&src"), 10 | url: $("https://yande.re"+parseDomForHtml(element, "a&&href")).lazyRule(_ => parseDomForHtml(fetch(input), ".highres-show&&href")), 11 | col_type: 'pic_3' 12 | }) 13 | }); 14 | 15 | res.data = d; 16 | setHomeResult(res); 17 | } 18 | 19 | const secParse = _ => { 20 | let res = {}; 21 | let d = []; 22 | const html = getResCode(); 23 | 24 | d.push({ 25 | pic_url: parseDomForHtml(html, ".highres-show&&href"), 26 | url: parseDomForHtml(html, ".highres-show&&href"), 27 | col_type: 'image_1_full' 28 | }) 29 | res.data = d; 30 | setHomeResult(res); 31 | } 32 | 33 | const searchParse = _ => { 34 | let res = {}; 35 | let d = []; 36 | const html = getResCode(); 37 | const list = parseDomForArray(html, "#post-list-posts&&li"); 38 | 39 | list.forEach(element => { 40 | d.push({ 41 | title: '', 42 | desc: '', 43 | pic_url: parseDomForHtml(element, ".preview&&src"), 44 | url: "https://yande.re"+parseDomForHtml(element, "a&&href") 45 | }) 46 | }); 47 | 48 | res.data = d; 49 | setHomeResult(res); 50 | } -------------------------------------------------------------------------------- /HOME/index.html: -------------------------------------------------------------------------------- 1 | drag-grid
    -------------------------------------------------------------------------------- /IMAGE/ChilloutMix.js: -------------------------------------------------------------------------------- 1 | js: 2 | addListener('onRefresh', $.toString(()=>{ 3 | putMyVar('ChilloutMix.TG.cursor', '0') 4 | })) 5 | const d = [] 6 | const empty = 'hiker://empty' 7 | const categoryIndex = getMyVar('ChilloutMix.TG.categoryIndex', 'all') 8 | const cursor = getMyVar('ChilloutMix.TG.cursor', '0') 9 | const page = parseInt(MY_PAGE) || 1 10 | 11 | 12 | if (page === 1) { 13 | const categories = [ 14 | {id: 'all', title: '全部'}, 15 | {id: ' { 21 | d.push({ 22 | title: categoryIndex === category.id ? '‘‘’’'+category.title+'' : category.title, 23 | url: $(empty).lazyRule((id) => { 24 | putMyVar("ChilloutMix.TG.categoryIndex", id) 25 | putMyVar("ChilloutMix.TG.cursor", '0') 26 | refreshPage(true) 27 | return "hiker://empty" 28 | }, category.id), 29 | col_type: 'scroll_button', 30 | }) 31 | }) 32 | d.push({ 33 | col_type: 'blank_block', 34 | }) 35 | } 36 | 37 | const input = {0:{json:{style:categoryIndex,template_name:"chilloutmix",cursor:parseInt(cursor)}}} 38 | const url = "https://chilloutai.com/api/trpc/task.allpic?batch=1&input="+encodeURIComponent(JSON.stringify(input)) 39 | 40 | try { 41 | const result = JSON.parse(fetch(url)) 42 | log(result) 43 | const list = result[0].result.data.json 44 | const data = list.data 45 | putMyVar("ChilloutMix.TG.cursor", list.nextCursor.toString()) 46 | 47 | data.forEach(item => { 48 | d.push({ 49 | pic_url: item.image_url, 50 | url: item.image_url, 51 | col_type: 'pic_2_card', 52 | }) 53 | }) 54 | } catch(e) {} 55 | 56 | 57 | setResult(d) -------------------------------------------------------------------------------- /IMAGE/Hentai Cosplay.js: -------------------------------------------------------------------------------- 1 | const empty = 'hiker://empty' 2 | 3 | const baseParse = () => { 4 | const d = [] 5 | const type_arr = MY_URL.match(/com\/(.*?)\/page/) 6 | 7 | if (type_arr && type_arr.length === 2) { 8 | const type = type_arr[1] 9 | switch (type) { 10 | case 'ranking': 11 | case 'recently': 12 | archiveParse(d) 13 | break 14 | case 'search-video': 15 | case 'ranking-video': 16 | videoParse(d) 17 | break 18 | case 'ranking-tag': 19 | case 'ranking-keyword': 20 | case 'tag': 21 | tagParse(d) 22 | break 23 | case 'ranking-images': 24 | imageParse(d) 25 | break 26 | } 27 | } 28 | 29 | setResult(d) 30 | } 31 | 32 | const archiveParse = (d) => { 33 | const list = pdfa(getResCode(), '#image-list&&.image-list-item') 34 | list.forEach(item => { 35 | let url = 'https://hentai-cosplays.com/story/'+pdfh(item, 'a&&href').match(/image\/(.*?)\//)[1]+'/' 36 | d.push({ 37 | title: pdfh(item, '.image-list-item-title&&Text'), 38 | desc: pdfh(item, '.image-list-item-regist-date&&Text'), 39 | url: $(empty).lazyRule((url) => { 40 | require('hiker://page/az') 41 | return descParse(url) 42 | }, url), 43 | pic_url: pdfh(item, '.image-list-item-image&&img&&src'), 44 | col_type: 'movie_3_marquee', 45 | }) 46 | }) 47 | } 48 | 49 | const videoParse = (d) => { 50 | const list = pdfa(getResCode(), '#image-list&&.image-list-item') 51 | list.forEach(item => { 52 | d.push({ 53 | title: pdfh(item, '.image-list-item-title&&Text'), 54 | desc: pdfh(item, '.image-list-item-regist-date&&Text'), 55 | url: $(pd(item, 'a&&href')).lazyRule(() => { 56 | require('hiker://page/az') 57 | return descVideoParse(input) 58 | }), 59 | pic_url: pdfh(item, '.image-list-item-image&&img&&src'), 60 | col_type: 'movie_3_marquee', 61 | }) 62 | }) 63 | } 64 | 65 | const tagParse = (d) => { 66 | const list = pdfa(getResCode(), '#tags&&li') 67 | list.forEach(item => { 68 | d.push({ 69 | title: pdfh(item, 'a&&Text'), 70 | url: $(pd(item, 'a&&href')+'page/fypage/').rule(() => { 71 | require('hiker://page/az') 72 | let d = [] 73 | archiveParse(d) 74 | setResult(d) 75 | }), 76 | col_type: 'text_3', 77 | }) 78 | }) 79 | } 80 | 81 | const imageParse = (d) => { 82 | const list = pdfa(getResCode(), '#wrapper&&#container&&.item') 83 | list.forEach(item => { 84 | let url = 'https://hentai-cosplays.com/story/'+pdfh(item, 'a&&href').match(/image\/(.*?)\/attachment/)[1]+'/' 85 | d.push({ 86 | title: pdfh(item, 'img&&alt'), 87 | url: $(empty).lazyRule((url) => { 88 | require('hiker://page/az') 89 | return descParse(url) 90 | }, url), 91 | pic_url: pdfh(item, 'img&&data-original'), 92 | col_type: 'movie_3_marquee', 93 | }) 94 | }) 95 | } 96 | 97 | const descParse = (url) => { 98 | const html = request(url) 99 | const list = pdfa(html, 'amp-story&&-story-page') 100 | const images = [] 101 | 102 | list.forEach(item => { 103 | images.push(pdfh(item, 'amp-img&&src')) 104 | }) 105 | 106 | return 'pics://'+images.join('&&') 107 | } 108 | 109 | const descVideoParse = (url) => { 110 | const html = request(url) 111 | const match = html.match(/"contentUrl": "(.*?)",/) 112 | 113 | return match[1] 114 | } 115 | 116 | const searchParse = () => { 117 | const d = [] 118 | archiveParse(d) 119 | setResult(d) 120 | } 121 | -------------------------------------------------------------------------------- /IMAGE/artstation.js: -------------------------------------------------------------------------------- 1 | const baseParse = _ => { 2 | let d = []; 3 | const page = MY_URL.match(/\?page=(.*?)&/)[1] 4 | const cookie = fetchCookie(MY_URL, {withHeaders: true}) 5 | 6 | // 设置 Cookie 7 | putVar("tyrantgenesis.artstation.cookie", cookie[0]); 8 | const channels_json = getResCode().match(/window.preloadedChannels = (.*?);<\/script>/)[1] 9 | const channels = JSON.parse(channels_json).data 10 | 11 | // 选择 12 | const channel_sel = getVar("tyrantgenesis.artstation.channel", channels[0].id.toString()); 13 | 14 | if (parseInt(page) === 1) { 15 | channels.forEach(item => { 16 | d.push({ 17 | title: item.id.toString()===channel_sel? "““"+item.name+"””":item.name, 18 | url: $("#noLoading#").lazyRule((item)=>{ 19 | putVar("tyrantgenesis.artstation.channel",item.id.toString()); 20 | refreshPage(false); 21 | return "hiker://empty" 22 | }, item), 23 | col_type: 'scroll_button' 24 | }); 25 | }) 26 | } 27 | 28 | const url = "https://www.artstation.com/api/v2/community/channels/projects.json?page="+page+"&per_page=30&sorting=trending&dimension=3d&channel_id="+channel_sel 29 | const list_json = fetch(url) 30 | const list = JSON.parse(list_json).data 31 | 32 | list.forEach(item => { 33 | d.push({ 34 | // title: item.title, 35 | url: item.url, 36 | pic_url: item.smaller_square_cover_url, 37 | // desc: item.user.username, 38 | col_type: 'pic_3' 39 | }); 40 | }) 41 | 42 | setResult(d); 43 | } 44 | 45 | 46 | const secParse = _ => { 47 | let d = []; 48 | const html = fetch(MY_URL, {headers:{"User-Agent": PC_UA, "Cookie": getVar("tyrantgenesis.artstation.cookie")}}) 49 | const images_json = html.match(/assets(.*?),\\"collections/)[1].replace('\\":', '').replace(/\\\\\\/g,'标志NMSL标志').replace(/\\/g,'').replace(/标志NMSL标志/g,'\\') 50 | const images = JSON.parse(images_json) 51 | 52 | images.forEach(item => { 53 | if (item.has_image) { 54 | d.push({ 55 | pic_url: item.image_url, 56 | url: item.image_url, 57 | col_type: 'pic_1_full' 58 | }) 59 | } 60 | }) 61 | 62 | setResult(d); 63 | } -------------------------------------------------------------------------------- /IMAGE/cos.js: -------------------------------------------------------------------------------- 1 | js: 2 | let d = [] 3 | const empty = "hiker://empty" 4 | 5 | const makeScroll = (url, cate_level) => { 6 | let json = fetch(url) 7 | let data = JSON.parse(json).data 8 | if (data) { 9 | let arr = data.files 10 | let first = arr[0] 11 | let cate_select = getVar("tyrantgenesis.images.cate_select_"+cate_level) 12 | let type = true 13 | let hasName = false 14 | arr.forEach(item => { 15 | if (item.type === 'FILE') type = false 16 | if (item.name === cate_select) hasName = true 17 | }) 18 | if (! hasName) cate_select = first.name 19 | if (type) { 20 | arr.forEach(cate => { 21 | if (cate.type === 'FOLDER') { 22 | cate.cate_level = cate_level 23 | d.push({ 24 | title: cate_select === cate.name ? '‘‘’’'+cate.name+'' : cate.name, 25 | url: $(empty).lazyRule(cate => { 26 | putVar("tyrantgenesis.images.cate_select_"+cate.cate_level, cate.name) 27 | refreshPage(false) 28 | return "hiker://empty" 29 | }, cate), 30 | col_type: 'scroll_button', 31 | }) 32 | } 33 | }) 34 | d.push({ 35 | col_type:"blank_block" 36 | }) 37 | 38 | cate_level++ 39 | makeScroll(url+"%2F"+encodeURIComponent(cate_select), cate_level) 40 | } else { 41 | arr.forEach(cate => { 42 | d.push({ 43 | pic_url: cate.url, 44 | url: cate.url, 45 | }) 46 | }) 47 | } 48 | } 49 | } 50 | 51 | makeScroll("https://zfile.cosersets.com/api/list/1?path=", 1) 52 | 53 | setResult(d); 54 | -------------------------------------------------------------------------------- /IMAGE/zcool.js: -------------------------------------------------------------------------------- 1 | const baseParse = _ => { 2 | // 初始化 3 | let d = []; 4 | const cate_url = "https://www.zcool.com.cn/p1/category/list-discover" 5 | const empty = "hiker://empty" 6 | const page = MY_URL.split('##')[1] 7 | const sort = [ 8 | {title: '编辑精选', url: 'recommend_level=2&sort=9'}, 9 | {title: '首页推荐', url: 'recommend_level=3&sort=9'}, 10 | {title: '全部推荐', url: 'recommend_level=1&sort=9'}, 11 | {title: '最新发布', url: 'recommend_level=0&sort=0'}] 12 | 13 | // 缓存 14 | let cate_1st = getVar("tyrantgenesis.zcool.cate_1st_select", "0") 15 | let cate_2nd = getVar("tyrantgenesis.zcool.cate_2nd_select", "0") 16 | let cate_sort = getVar("tyrantgenesis.zcool.cate_sort", "0") 17 | 18 | const api_url = MY_URL.split('##')[0] + "?cate="+cate_1st+"&sub_cate="+cate_2nd+"&has_video=0&city=0&college=0&"+sort[cate_sort].url+"&ps=20&p="+page 19 | 20 | // 一级分类 21 | const category_json = fetch(cate_url, {headers:{"User-Agent": PC_UA}}) 22 | const category = JSON.parse(category_json).datas 23 | 24 | if (parseInt(page) === 1) { 25 | 26 | // 一级分类 27 | category.forEach(cate => { 28 | d.push({ 29 | title: cate_1st === cate.id.toString() ? '‘‘’’'+cate.name+'' : cate.name, 30 | url: $(empty).lazyRule(params => { 31 | putVar("tyrantgenesis.zcool.cate_1st_select", params.cate_id.toString()) 32 | putVar("tyrantgenesis.zcool.cate_2nd_select", "0") 33 | refreshPage(true) 34 | return "hiker://empty" 35 | }, { 36 | cate_id: cate.id, 37 | }), 38 | col_type: 'scroll_button' 39 | }) 40 | }) 41 | d.push({ 42 | col_type: 'blank_block', 43 | }) 44 | 45 | // 二级分类 46 | let sub_category = category.find(item => item.id.toString() === cate_1st).subCateList 47 | d.push({ 48 | title: cate_2nd === "0" ? '‘‘’’全部' : '全部', 49 | url: $(empty).lazyRule(params => { 50 | putVar("tyrantgenesis.zcool.cate_2nd_select", "0") 51 | refreshPage(true) 52 | return "hiker://empty" 53 | }), 54 | col_type: 'scroll_button' 55 | }) 56 | sub_category.forEach(cate => { 57 | d.push({ 58 | title: cate_2nd === cate.id.toString() ? '‘‘’’'+cate.name+'' : cate.name, 59 | url: $(empty).lazyRule(params => { 60 | putVar("tyrantgenesis.zcool.cate_2nd_select", params.cate_id.toString()) 61 | refreshPage(true) 62 | return "hiker://empty" 63 | }, { 64 | cate_id: cate.id 65 | }), 66 | col_type: 'scroll_button' 67 | }) 68 | }) 69 | d.push({ 70 | col_type: 'blank_block', 71 | }) 72 | 73 | // 三级分类 74 | sort.forEach((item, index) => { 75 | d.push({ 76 | title: cate_sort === index.toString() ? '‘‘’’'+item.title+'' : item.title, 77 | url: $(empty).lazyRule(params => { 78 | putVar("tyrantgenesis.zcool.cate_sort", params.cate_id.toString()) 79 | refreshPage(true) 80 | return "hiker://empty" 81 | }, { 82 | cate_id: index 83 | }), 84 | col_type: 'scroll_button' 85 | }) 86 | }) 87 | d.push({ 88 | col_type: 'blank_block', 89 | }) 90 | } 91 | 92 | const list_json = fetch(api_url, {headers:{"User-Agent": PC_UA}}) 93 | const list = JSON.parse(list_json).datas 94 | 95 | list.forEach(item => { 96 | if (item.objectType === 3) { 97 | let obj = item.content 98 | d.push({ 99 | title: obj.title, 100 | desc: obj.creatorObj.username, 101 | pic_url: obj.cover, 102 | url: $("https://www.zcool.com.cn/work/"+obj.idStr+".html").rule(_ => { 103 | eval(fetch('hiker://files/TyrantG/IMAGE/zcool.js')) 104 | secParse(MY_URL) 105 | }), 106 | col_type: 'movie_2' 107 | }) 108 | } 109 | }) 110 | 111 | setResult(d); 112 | } 113 | 114 | const secParse = MY_URL => { 115 | let d = []; 116 | const pageContent = fetch(MY_URL, {headers:{"User-Agent": PC_UA}}) 117 | const html = parseDomForHtml(pageContent, '.workShowBox&&Html'); 118 | 119 | d.push({ 120 | title: html.replace(/收藏/g, '').replace(//, ''), 121 | col_type: 'rich_text' 122 | }) 123 | 124 | setResult(d); 125 | } 126 | 127 | const searchParse = _ => { 128 | let d = []; 129 | const list = JSON.parse(getResCode()).datas 130 | 131 | list.forEach(item => { 132 | if (item.objectType === 3) { 133 | let obj = item.content 134 | d.push({ 135 | title: obj.title, 136 | desc: obj.creatorObj.username, 137 | pic_url: obj.cover, 138 | url: $("https://www.zcool.com.cn/work/"+obj.idStr+".html").rule(_ => { 139 | eval(fetch('hiker://files/TyrantG/IMAGE/zcool.js')) 140 | secParse(MY_URL) 141 | }), 142 | col_type: 'movie_2' 143 | }) 144 | } 145 | }) 146 | 147 | setResult(d); 148 | } 149 | -------------------------------------------------------------------------------- /LIVE/17live.js: -------------------------------------------------------------------------------- 1 | const baseParse = _ => { 2 | let d = []; 3 | const html = getResCode() 4 | const list = JSON.parse(html).cells 5 | 6 | list.forEach(item => { 7 | if (item.type === 0) { 8 | let stream = item.stream 9 | if (stream.rtmpUrls && stream.rtmpUrls.length > 0) { 10 | d.push({ 11 | title: stream.caption, 12 | pic_url: "https://cdn.17app.co/THUMBNAIL_"+stream.thumbnail, 13 | url: stream.rtmpUrls[0].url 14 | .replace("wansu-global-pull-rtmp-latency.17app.co", "wansu-china-pull-rtmp-latency-17.tigafocus.com") 15 | .replace("wansu-global-pull-rtmp.17app.co", "wansu-china-pull-rtmp-17.tigafocus.com"), 16 | desc: stream.userInfo.displayName, 17 | }) 18 | } 19 | } 20 | }) 21 | 22 | setResult(d); 23 | } 24 | 25 | const searchParse = _ => { 26 | let d = []; 27 | const html = getResCode() 28 | const list = JSON.parse(html) 29 | 30 | list.forEach(item => { 31 | if (item.user.roomID) { 32 | d.push({ 33 | title: item.user.picture, 34 | pic_url: "https://cdn.17app.co/THUMBNAIL_"+item.user.picture, 35 | url: $("https://api-dsa.17app.co/api/v1/lives/"+item.user.roomID).lazyRule(() => { 36 | const html = fetch(input) 37 | const item = JSON.parse(html) 38 | 39 | if (item.rtmpUrls && item.rtmpUrls.length > 0) { 40 | return item.rtmpUrls[0].url 41 | .replace("wansu-global-pull-rtmp-latency.17app.co", "wansu-china-pull-rtmp-latency-17.tigafocus.com") 42 | .replace("wansu-global-pull-rtmp.17app.co", "wansu-china-pull-rtmp-17.tigafocus.com") 43 | } else 44 | return '房间号未找到' 45 | }), 46 | desc: item.user.name, 47 | }) 48 | } 49 | }) 50 | 51 | setResult(d); 52 | } -------------------------------------------------------------------------------- /LIVE/95_xiu.js: -------------------------------------------------------------------------------- 1 | const baseParse = _ => { 2 | let d = []; 3 | const html = getResCode() 4 | const list = parseDomForArray(html, 'html&&li'); 5 | 6 | list.forEach(item => { 7 | let uid = parseDomForHtml(item, 'a&&href').match(/\/(.*?)\./)[1] 8 | d.push({ 9 | title: parseDomForHtml(item, '.pane_mm_name&&Text'), 10 | url: "http://play.95xiu.com/app/"+uid+".flv", 11 | pic_url: parseDomForHtml(item, 'img&&src'), 12 | col_type: 'movie_2' 13 | }); 14 | }) 15 | 16 | 17 | setResult(d); 18 | } 19 | 20 | const searchParse = _ => { 21 | let d = []; 22 | const html = getResCode() 23 | const list = parseDomForArray(html, 'html&&li'); 24 | 25 | list.forEach(item => { 26 | let uid = parseDomForHtml(item, 'a&&href').match(/\/(.*?)\./)[1] 27 | d.push({ 28 | title: parseDomForHtml(item, '.pane_mm_name&&Text'), 29 | url: "http://play.95xiu.com/app/"+uid+".flv", 30 | desc: "404就是没开播", 31 | pic_url: parseDomForHtml(item, 'img&&src'), 32 | col_type: 'movie_2' 33 | }); 34 | }) 35 | 36 | 37 | setResult(d); 38 | } -------------------------------------------------------------------------------- /LIVE/collection/index.js: -------------------------------------------------------------------------------- 1 | const streamLab = { 2 | d: [], 3 | empty: 'hiker://empty', 4 | streamNameList: [ 5 | {title: '斗鱼', key: 'douyu',}, 6 | {title: '虎牙', key: 'huya',}, 7 | ], 8 | streamKey: getItem('TyrantGenesis.streamLab.streamKey', 'douyu'), 9 | baseParse: () => { 10 | addListener('onClose', $.toString(() => { 11 | clearItem('TyrantGenesis.streamLab.streamKey') 12 | clearItem('TyrantGenesis.streamLab.FirstCate') 13 | clearItem('TyrantGenesis.streamLab.SecondCate') 14 | })) 15 | const page = MY_URL.split('##')[1] 16 | if (page === '1') { 17 | streamLab.d.push({ 18 | title: 'Search', 19 | col_type: 'icon_1_search', 20 | }) 21 | streamLab.d.push({ 22 | title: '⚙', 23 | col_type: 'scroll_button', 24 | }) 25 | streamLab.streamNameList.forEach((stream, index) => { 26 | streamLab.d.push({ 27 | title: streamLab.streamKey === stream.key ? '‘‘’’'+stream.title+'' : stream.title, 28 | url: $(streamLab.empty).lazyRule((key) => { 29 | setItem('TyrantGenesis.streamLab.streamKey', key) 30 | refreshPage(true) 31 | return 'hiker://empty' 32 | }, stream.key), 33 | col_type: 'scroll_button', 34 | }) 35 | }) 36 | streamLab.d.push({ 37 | col_type: 'blank_block', 38 | }) 39 | streamLab.categoryLoad() 40 | } 41 | streamLab.baseParseLoad(page) 42 | setResult(streamLab.d); 43 | }, 44 | categoryLoad: () => { 45 | switch (streamLab.streamKey) { 46 | case 'douyu': 47 | { 48 | $.require('hiker://page/douyu').categoryLoad(streamLab.d) 49 | } 50 | } 51 | }, 52 | baseParseLoad: (page) => { 53 | switch (streamLab.streamKey) { 54 | case 'douyu': 55 | { 56 | $.require('hiker://page/douyu').baseParseLoad(streamLab.d, page) 57 | } 58 | } 59 | }, 60 | } 61 | 62 | $.exports = streamLab 63 | -------------------------------------------------------------------------------- /LIVE/douyu_danmu.js: -------------------------------------------------------------------------------- 1 | const baseParse = _ => { 2 | let d = []; 3 | 4 | d.push({ 5 | desc: '48', 6 | url: 'file:///storage/emulated/0/Android/data/com.example.hikerview/files/Documents/rules/TyrantG/public/douyu-tabs.html', 7 | col_type:"x5_webview_single" 8 | }) 9 | 10 | const list_json = fetch("https://m.douyu.com/api/home/mix"); 11 | const list = JSON.parse(list_json) 12 | 13 | list.data.forEach(element => { 14 | let category_url = "https://m.douyu.com/api/room/list?page=fypage&type="+element.shortName 15 | d.push({ 16 | title: element.cate2Info[0].cate2Name, 17 | pic_url: element.icon, 18 | url: $(category_url).rule(_ => { 19 | eval(fetch('hiker://files/TyrantG/LIVE/douyu_danmu.js')) 20 | categoryParse() 21 | }), 22 | col_type: 'avatar' 23 | }) 24 | 25 | element.list.forEach(item => { 26 | d.push({ 27 | title: item.roomName, 28 | desc: item.nickname, 29 | pic_url: item.roomSrc, 30 | url: $("https://m.douyu.com/"+item.rid).lazyRule(_ => { 31 | eval(fetch('hiker://files/TyrantG/LIVE/douyu_danmu.js')) 32 | return secParse(input) 33 | }), 34 | col_type: 'movie_2' 35 | }) 36 | }) 37 | d.push({ 38 | col_type: 'line_blank' 39 | }) 40 | }); 41 | 42 | setResult(d); 43 | } 44 | 45 | const secParse = input => { 46 | const html = fetch(input) 47 | 48 | // const rid = parseInt(input.replace("https://m.douyu.com/", "")) 49 | const rid = html.match(/rid":(.*?),"vipId/)[1] 50 | const tt = Date.parse(new Date()).toString().substr(0,10) 51 | const did = "10000000000000000000000000001501" 52 | 53 | let param_body = getSign(html, rid, did, tt) 54 | 55 | const stream_json = fetch('https://m.douyu.com/api/room/ratestream', {headers:{'content-type':'application/x-www-form-urlencoded'}, body: param_body, method:'POST'}) 56 | const stream = JSON.parse(stream_json).data 57 | 58 | return JSON.stringify({ 59 | urls: [stream.url], 60 | // danmu: 'web://file:///storage/emulated/0/Android/data/com.example.hikerview/files/Documents/TyrantG/public/douyu_danmu.html?rid='+rid 61 | danmu: 'web://http://douyu_danmu.dev.tyrantg.com/?rid='+rid+'&ver=1' 62 | }) 63 | } 64 | 65 | const categoryParse = _ =>{ 66 | let d = []; 67 | const html = getResCode(); 68 | const list = JSON.parse(html).data 69 | 70 | list.list.forEach(item => { 71 | d.push({ 72 | title: item.roomName, 73 | desc: item.nickname, 74 | pic_url: item.roomSrc, 75 | url: $("https://m.douyu.com/"+item.rid).lazyRule(_ => { 76 | eval(fetch('hiker://files/TyrantG/LIVE/douyu_danmu.js')) 77 | return secParse(input) 78 | }), 79 | col_type: 'movie_2' 80 | }) 81 | }) 82 | 83 | 84 | setResult(d); 85 | } 86 | 87 | const searchParse = () => { 88 | let d = []; 89 | const html = getResCode(); 90 | const list = JSON.parse(html).data 91 | 92 | list.list.forEach(item => { 93 | d.push({ 94 | title: item.nickname, 95 | desc: item.roomName, 96 | pic_url: item.roomSrc, 97 | url: $("https://m.douyu.com/"+item.roomId).lazyRule(_ => { 98 | eval(fetch('hiker://files/TyrantG/LIVE/douyu_danmu.js')) 99 | return secParse(input) 100 | }), 101 | col_type: 'movie_2' 102 | }) 103 | }) 104 | 105 | setResult(d); 106 | } 107 | 108 | const cateGroupParse = _ => { 109 | let d = [] 110 | let list_json = fetch(MY_URL) 111 | let list = JSON.parse(list_json).data 112 | list.cate2Info.forEach(cate2 => { 113 | let category_url = "https://m.douyu.com/api/room/list?page=fypage&type="+cate2.shortName 114 | d.push({ 115 | title:cate2.cate2Name, 116 | pic_url:cate2.icon, 117 | url: $(category_url).rule(_ => { 118 | eval(fetch('hiker://files/TyrantG/LIVE/douyu_danmu.js')) 119 | categoryParse() 120 | }), 121 | col_type:"icon_round_4" 122 | }); 123 | }); 124 | setResult(d); 125 | } 126 | 127 | const getSign = (script, rid, did, tt) => { 128 | 129 | let result = script.match(/(function ub98484234.*)\s(var.*)/)[0] 130 | let func_ub9 = result.replace(/eval.*;}/, 'strc;}', result) 131 | eval(func_ub9) 132 | 133 | let res = ub98484234() 134 | let v = res.match(/v=(\d+)/)[0].replace("v=", '') 135 | let rb = md5(rid + did + tt + v) 136 | 137 | let func_sign = res.replace(/return rt;}\);?/, 'return rt;}') 138 | func_sign = func_sign.replace('(function (', 'function sign(') 139 | func_sign = func_sign.replace('CryptoJS.MD5(cb).toString()', '"' + rb + '"') 140 | eval(func_sign) 141 | 142 | let params = sign(rid, did, tt) + "&ver=219032101&rid={}&rate=-1&rid="+rid 143 | return params 144 | } 145 | -------------------------------------------------------------------------------- /LIVE/qie_egame.js: -------------------------------------------------------------------------------- 1 | const baseParse = _ => { 2 | let d = []; 3 | const list = JSON.parse(getResCode()).data[0].retBody.data.live_data.live_list 4 | 5 | d.push({ 6 | desc: '48', 7 | url: 'file:///storage/emulated/0/Android/data/com.example.hikerview/files/Documents/TyrantG/public/qieEgame-tabs.html?time='+(new Date()).getTime(), 8 | col_type:"x5_webview_single" 9 | }) 10 | 11 | list.forEach(item => { 12 | let data = JSON.parse(item.data_h5) 13 | d.push({ 14 | title: data.title, 15 | desc: data.anchor_name, 16 | pic_url: data.program_res.cover_url, 17 | col_type: 'movie_2', 18 | url: $(data.jump_url).lazyRule(_ => { 19 | eval(fetch('hiker://files/TyrantG/LIVE/qie_egame.js')) 20 | return secParse(input) 21 | }) 22 | }) 23 | }) 24 | 25 | setResult(d); 26 | } 27 | 28 | const secParse = input => { 29 | let urls = [] 30 | let names = [] 31 | const anchor_id = input.match(/anchorid=(.*?)&/)[1] 32 | const data_json = fetch("https://share.egame.qq.com/cgi-bin/pgg_async_fcgi", {headers: {"Content-Type": "application/x-www-form-urlencoded"}, method: 'POST', body: "param={\"0\":{\"module\":\"pgg_live_read_svr\",\"method\":\"get_live_and_profile_info\",\"param\":{\"anchor_id\":"+anchor_id+",\"layout_id\":\"hot\",\"index\":1,\"other_uid\":0}}}"}) 33 | 34 | const list = JSON.parse(data_json).data[0].retBody.data.video_info.stream_infos 35 | 36 | list.forEach(item => { 37 | urls.push(item.play_url) 38 | names.push(item.desc) 39 | // d.push({ 40 | // title: item.desc, 41 | // col_type: 'text_2', 42 | // url: item.play_url 43 | // }) 44 | }) 45 | 46 | return JSON.stringify({urls: urls, names: names}) 47 | } 48 | 49 | const cateGroupParse = _ => { 50 | let d = [] 51 | const html = fetch("https://egame.qq.com/gamelist/", {headers:{"User-Agent":PC_UA}}) 52 | const list = parseDomForArray(html, '.livelist-mod&&.gui-list-game'); 53 | 54 | list.forEach(item => { 55 | d.push({ 56 | title: parseDomForHtml(item, 'a&&title'), 57 | pic_url: parseDomForHtml(item, 'img&&src'), 58 | url: $(parseDom(item, 'a&&href')+'&page=fypage&_=_').rule(_ => { 59 | let d = []; 60 | const layout_id = MY_URL.match(/layoutid=(.*?)&/)[1] 61 | const page = MY_URL.match(/page=(.*?)&/)[1] 62 | 63 | const data_json = fetch("https://share.egame.qq.com/cgi-bin/pgg_kit_async_fcgi", {headers: {"Content-Type": "application/x-www-form-urlencoded"}, method: 'POST', body: "param={\"0\":{\"param\":{\"layout_id\":\""+layout_id+"\",\"page_num\":"+page+",\"page_size\":16,\"scene\":0,\"tag_id\":0},\"module\":\"pgg_live_read_svr\",\"method\":\"get_live_list\"}}"}) 64 | 65 | const list = JSON.parse(data_json).data[0].retBody.data.live_data.live_list 66 | 67 | list.forEach(item => { 68 | d.push({ 69 | title: item.title, 70 | desc: item.anchor_name, 71 | pic_url: item.program_res.cover_url, 72 | col_type: 'movie_2', 73 | url: $(item.jump_url).lazyRule(_ => { 74 | eval(fetch('hiker://files/TyrantG/LIVE/qie_egame.js')) 75 | return secParse(input) 76 | }) 77 | }) 78 | }) 79 | 80 | setResult(d); 81 | }), 82 | col_type: 'movie_3', 83 | }) 84 | }) 85 | 86 | setResult(d); 87 | } 88 | 89 | const searchParse = _ => { 90 | let d = [] 91 | const html = fetch(MY_URL, {headers:{"User-Agent":PC_UA}}) 92 | const list = parseDomForArray(html, '.livelist-mod&&.gui-list-normal'); 93 | 94 | list.forEach(item => { 95 | d.push({ 96 | title: parseDomForHtml(item, 'a&&title'), 97 | pic_url: parseDom(item, 'img&&src'), 98 | col_type: 'movie_2', 99 | url: $("https://m.egame.qq.com/live?anchorid="+parseDomForHtml(item, 'a&&href').split('/').pop()+"&_=_").lazyRule(_ => { 100 | eval(fetch('hiker://files/TyrantG/LIVE/qie_egame.js')) 101 | return secParse(input) 102 | }) 103 | }) 104 | }) 105 | 106 | setResult(d) 107 | } -------------------------------------------------------------------------------- /LIVE/qie_sport.js: -------------------------------------------------------------------------------- 1 | const baseParse = _ => { 2 | let d = []; 3 | const category_json = fetch("https://live.qq.com/api/ajax/get_column_category") 4 | const page = MY_URL.match(/\?page\=(.*?)\&/)[1] 5 | const category = JSON.parse(category_json).data.leftNav 6 | const current = getMyVar("tyrantgenesis.qie_sport.current_tab") || 0; 7 | const current_child = getMyVar("tyrantgenesis.qie_sport.current_child_tab") || ''; 8 | 9 | const child_cate_url = "https://live.qq.com/app_api/v10/getChildList?short_name="+category[current].short_name 10 | const child_category_json = fetch(child_cate_url) 11 | const child_list = JSON.parse(child_category_json).data 12 | 13 | const data_url = "https://live.qq.com/api/live/vlist?page_size=16&page="+page+"&shortName="+category[current].short_name+"&child_id="+current_child 14 | const data_json = fetch(data_url) 15 | const list = JSON.parse(data_json).data.result 16 | 17 | if (parseInt(page) === 1) { 18 | category.forEach((item, index) => { 19 | d.push({ 20 | title: index==current? "““"+item.tag_name+"””":item.tag_name, 21 | url: $("#noLoading#").lazyRule((index)=>{ 22 | putMyVar("tyrantgenesis.qie_sport.current_tab",index); 23 | putMyVar("tyrantgenesis.qie_sport.current_child_tab",''); 24 | refreshPage(false); 25 | return "hiker://empty" 26 | }, index) 27 | }); 28 | }) 29 | d.push({ 30 | col_type:"blank_block" 31 | }); 32 | d.push({ 33 | title: current_child === '' ? "““全部””":"全部", 34 | url: $("#noLoading#").lazyRule(_ => { 35 | putMyVar("tyrantgenesis.qie_sport.current_child_tab",''); 36 | refreshPage(false); 37 | return "hiker://empty" 38 | }) 39 | }); 40 | child_list.forEach((child, key) => { 41 | d.push({ 42 | title: child.child_id==current_child? "““"+child.child_name+"””":child.child_name, 43 | url: $("#noLoading#").lazyRule((key)=>{ 44 | putMyVar("tyrantgenesis.qie_sport.current_child_tab",key); 45 | refreshPage(false); 46 | return "hiker://empty" 47 | }, child.child_id) 48 | }); 49 | }) 50 | } 51 | 52 | list.forEach(video => { 53 | d.push({ 54 | title: video.room_name, 55 | url: $('https://m.live.qq.com/'+video.room_id).lazyRule((id) => { 56 | const api_url = "https://live.qq.com/api/h5/room?room_id="+id 57 | const res = JSON.parse(fetch(api_url)).data 58 | // return res.rtmp_url.replace('http', 'https') + '/' + res.rtmp_live 59 | return res.hls_url 60 | // return html.match(/"hls_url":"(.*?)","use_p2p"/)[1]+"@Referer=" 61 | }, video.room_id), 62 | pic_url: video.room_src+"@Referer=", 63 | col_type: 'movie_2' 64 | }); 65 | }) 66 | 67 | 68 | setResult(d); 69 | } 70 | 71 | const searchParse = _ => { 72 | let d = []; 73 | const list = JSON.parse(getResCode()).room 74 | 75 | list.forEach(video => { 76 | d.push({ 77 | title: video.room_name, 78 | url: $('https://m.live.qq.com/'+video.room_id).lazyRule((id) => { 79 | const api_url = "https://live.qq.com/api/h5/room?room_id="+id 80 | const res = JSON.parse(fetch(api_url)).data 81 | // return res.rtmp_url.replace('http', 'https') + '/' + res.rtmp_live 82 | return res.hls_url 83 | // const html = fetch(input) 84 | // return html.match(/"hls_url":"(.*?)","use_p2p"/)[1]+"@Referer=" 85 | }, video.room_id), 86 | desc: video.nickname, 87 | pic_url: video.room_src+"@Referer=", 88 | }); 89 | }) 90 | 91 | setResult(d); 92 | } 93 | -------------------------------------------------------------------------------- /LIVE/twitch.js: -------------------------------------------------------------------------------- 1 | const baseParse = _ => { 2 | let d = []; 3 | const url = MY_URL 4 | const header = {'Accept': 'application/vnd.twitchtv.v5+json', 'Client-ID' : '7i8imjlwj0oqyiu3rutgfayf17op3w'} 5 | const data_json = fetch(url, {headers: header}) 6 | const list = JSON.parse(data_json).top 7 | list.forEach(item => { 8 | d.push({ 9 | title: item.game.name, 10 | desc: item.viewers+'人观看', 11 | pic_url: item.game.box.medium, 12 | url: "https://api.twitch.tv/kraken/streams/?game="+encodeURIComponent(item.game.name)+"&offset=fypage@-1@*24@&limit=24", 13 | }) 14 | }) 15 | 16 | setResult(d); 17 | } 18 | 19 | const secParse = _ => { 20 | let d = []; 21 | const header = {'Accept': 'application/vnd.twitchtv.v5+json', 'Client-ID' : '7i8imjlwj0oqyiu3rutgfayf17op3w', 'User-Agent': PC_UA} 22 | const data_json = fetch(MY_URL, {headers: header}) 23 | 24 | const list = JSON.parse(data_json).streams 25 | list.forEach(item => { 26 | let channel = item.channel 27 | d.push({ 28 | title: channel.status, 29 | desc: channel.display_name, 30 | pic_url: item.preview.medium, 31 | url: $(channel.url).lazyRule(_ => { 32 | eval(fetch('hiker://files/TyrantG/LIVE/twitch.js')) 33 | const header = {'User-Agent': PC_UA} 34 | const html = fetch(input, {headers: header}) 35 | const client_id = html.match(/"Client-ID":"(.*?)"/)[1] 36 | const rid = input.split('/').pop() 37 | 38 | const data = { 39 | "operationName": "PlaybackAccessToken", 40 | "extensions": { 41 | "persistedQuery": { 42 | "version": 1, 43 | "sha256Hash": "0828119ded1c13477966434e15800ff57ddacf13ba1911c129dc2200705b0712" 44 | } 45 | }, 46 | "variables": { 47 | "isLive": true, 48 | "login": rid, 49 | "isVod": true, 50 | "vodID": "", 51 | "playerType": "site" 52 | } 53 | } 54 | 55 | const headers = { 56 | 'Client-ID': client_id, 57 | 'Content-Type': 'application/json', 58 | 'Referer': 'https://www.twitch.tv/', 59 | 'User-Agent': 'Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/90.0.4430.214 Safari/537.36' 60 | } 61 | 62 | const data_json = fetch('https://gql.twitch.tv/gql', {headers: headers, method:'POST', body: JSON.stringify(data)}) 63 | const value = JSON.parse(data_json).data.streamPlaybackAccessToken.value 64 | const signature = JSON.parse(data_json).data.streamPlaybackAccessToken.signature 65 | 66 | const stream_url = 'https://usher.ttvnw.net/api/channel/hls/'+rid+'.m3u8' + 67 | '?client_id=' + client_id + 68 | '&token=' + encodeURIComponent(value) + 69 | '&sig=' + signature + 70 | '&allow_source=true'/* + 71 | '&allow_audio_only=true'*/ 72 | 73 | const playlist = fetch(stream_url) 74 | 75 | const lines = playlist.split('\n'); 76 | 77 | if (lines.length < 5) { 78 | return "toast://当前主播没有在直播" 79 | } else { 80 | /* d.push({ 81 | title: "如果显示“commercial break in progress”请等15秒", 82 | col_type: 'text_center_1' 83 | }); */ 84 | let urls = []; 85 | let names = []; 86 | for (let i = 4; i < lines.length; i += 3) { 87 | // urls.push(m3u8Parse(lines[i], i)); 88 | urls.push(lines[i]); 89 | names.push(lines[i - 2].split('NAME="')[1].split('"')[0]); 90 | // d.push({ 91 | // title: lines[i - 2].split('NAME="')[1].split('"')[0], 92 | // // resolution: (lines[i - 1].indexOf('RESOLUTION') != -1 ? lines[i - 1].split('RESOLUTION=')[1].split(',')[0] : null), 93 | // url: lines[i], 94 | // col_type: 'text_2' 95 | // }); 96 | } 97 | return JSON.stringify({urls: urls, names: names}) 98 | } 99 | 100 | }), 101 | col_type: 'movie_2' 102 | }) 103 | }) 104 | 105 | setResult(d); 106 | } 107 | 108 | 109 | const m3u8Parse = (url, id) => { 110 | const oriM3U8Content = fetch(url).split('\n') 111 | const newM3U8Content = [] 112 | const position = [] 113 | oriM3U8Content.forEach((item, index) => { 114 | if (item.indexOf('#EXTINF:2.002,Amazon') != -1) { 115 | position.push(index+1) 116 | } 117 | if (position.indexOf(index) == -1) { 118 | newM3U8Content.push(item) 119 | } 120 | }) 121 | 122 | writeFile("hiker://files/cache/TyrantG/twitch_temp_"+id+".m3u8", newM3U8Content.join('\n')) 123 | return "file:///storage/emulated/0/Android/data/com.example.hikerview/files/Documents/cache/TyrantG/twitch_temp_"+id+".m3u8" 124 | } -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # 摆烂 2 | -------------------------------------------------------------------------------- /TEST/acfun-bangumilist.js: -------------------------------------------------------------------------------- 1 | const baseParse = _ => { 2 | let d = [] 3 | const category_html = getResCode() 4 | const categories = parseDomForArray(category_html, '.ac-menu&&.ac-menu-filter') 5 | let category_list = [] 6 | 7 | const base_url = MY_URL.split('?')[0] 8 | 9 | const pageNum = getUrlParams(MY_URL, base_url, 'pageNum') 10 | 11 | const true_url = addUrlPara(getVar('tab-url') || MY_URL, 'pageNum', pageNum) 12 | 13 | const filters = getUrlParams(true_url, base_url, 'filters') || '' 14 | 15 | categories.forEach(category => { 16 | let sub_list = [] 17 | let category_sub = parseDomForArray(category, '.ac-menu-filter-content&&.ac-menu-filter-item') 18 | category_sub.forEach(sub => { 19 | sub_list.push({ 20 | id: parseDomForHtml(sub, '.ac-menu-filter-item&&data-id'), 21 | name: parseDomForHtml(sub, '.ac-menu-filter-item&&Text'), 22 | }) 23 | }) 24 | category_list.push({ 25 | name: parseDomForHtml(category, '.ac-menu-filter-title&&Text').slice(0,-1), 26 | list: sub_list 27 | }) 28 | }) 29 | 30 | putVar('tab-panel', JSON.stringify(category_list)) 31 | 32 | d.push({ 33 | desc: '118 && float', 34 | url: 'file:///storage/emulated/0/Android/data/com.example.hikerview/files/Documents/TyrantG/public/category.html?filters='+filters, 35 | col_type:"x5_webview_single" 36 | }) 37 | 38 | const list = parseDomForArray(fetch(true_url, {headers:{"User-Agent":PC_UA}}), '.ac-mod-ul&&.ac-mod-li') 39 | 40 | list.forEach(item => { 41 | d.push({ 42 | title: parseDomForHtml(item, '.ac-mod-title&&title'), 43 | pic_url: parseDomForHtml(item, 'img&&src'), 44 | url: parseDomForHtml(item, '.ac-mod-link&&href'), 45 | }) 46 | }) 47 | 48 | setResult(d); 49 | } 50 | 51 | const secParse = _ => { 52 | var res = {};var d = []; 53 | var url = MY_URL!=getVar('url',MY_URL).split('_')[0]?MY_URL:getVar('url',MY_URL); 54 | var title = getVar('title'); 55 | var code = request(url,{headers:{"User-Agent":PC_UA}}); 56 | try{ 57 | var rurl = code.replace(/\\/g,'').split('backupUrl":["')[1].split('"')[0]; 58 | }catch(e){var rurl = url} 59 | d.push({ 60 | title: "““当前集数:"+title, 61 | url:rurl, 62 | col_type:"text_1" 63 | }); 64 | 65 | 66 | 67 | d.push({ 68 | title: "选集", 69 | col_type:"rich_text" 70 | }); 71 | var json =code.split('window.bangumiList = ')[1].split('};')[0]+'}'; 72 | var jsons = JSON.parse(json); 73 | var list = jsons.items; 74 | for (let x of list){ 75 | var a = MY_URL+'_36188_'+x.itemId; 76 | var b = x.title; 77 | var c =a+'&&'+b; 78 | d.push({ 79 | title: b==title? '““'+x.episodeName+'””':x.episodeName, 80 | img:x.image, 81 | url:$("#noLoading#").lazyRule((c)=>{ 82 | putVar("url",c.split('&&')[0]); 83 | putVar("title",c.split('&&')[1]); 84 | refreshPage(false); 85 | var url = MY_URL!=getVar('url',MY_URL).split('_')[0]?MY_URL:getVar('url',MY_URL); 86 | var title = getVar('title'); 87 | var code = request(url,{headers:{"User-Agent":PC_UA}}); 88 | try{ 89 | var rurl=code.replace(/\\/g,'').split('backupUrl":["')[1].split('"')[0]; 90 | }catch(e){var rurl = url} 91 | return rurl; 92 | return "hiker://empty" 93 | }, c), 94 | col_type:'text_3' 95 | }); 96 | 97 | } 98 | res.data = d; 99 | setResult(res); 100 | } 101 | 102 | const searchParse = _ => { 103 | var res = {};var d = []; 104 | var code = request(MY_URL,{}); 105 | var bgm = JSON.parse(code).bgmList; 106 | for (let x of bgm){ 107 | d.push({ 108 | title:x.bgmTitle, 109 | img:x.coverImageH, 110 | desc:x.contentCount, 111 | content:x.bgmIntro, 112 | url:'https://www.acfun.cn/bangumi/aa'+x.bgmId, 113 | col_type:'movie_1_left_pic' 114 | }); 115 | } 116 | res.data = d; 117 | setResult(res); 118 | } 119 | 120 | const getUrlParams = (url, baseUrl, name) => { 121 | let reg = new RegExp("(^|&)" + name + "=([^&]*)(&|$)", "i"); //定义正则表达式 122 | let r = url.replace(baseUrl, '').substr(1).match(reg); 123 | if (r != null) return unescape(r[2]); 124 | return null; 125 | } 126 | 127 | const addUrlPara = (url, name, value) => { 128 | let currentUrl = url.split('#')[0]; 129 | if (/\?/g.test(currentUrl)) { 130 | if (/name=[-\w]{4,25}/g.test(currentUrl)) { 131 | currentUrl = currentUrl.replace(/name=[-\w]{4,25}/g, name + "=" + value); 132 | } else { 133 | currentUrl += "&" + name + "=" + value; 134 | } 135 | } else { 136 | currentUrl += "?" + name + "=" + value; 137 | } 138 | return currentUrl 139 | } -------------------------------------------------------------------------------- /TEST/new-homepage.js: -------------------------------------------------------------------------------- 1 | const homePage = _ => { 2 | let d = []; 3 | 4 | d.push({ 5 | desc: '100% && float', 6 | url: 'file:///storage/emulated/0/Android/data/com.example.hikerview/files/Documents/TyrantG/HOME/index.html?time='+(new Date()).getTime(), 7 | col_type:"x5_webview_single" 8 | }) 9 | 10 | setResult(d); 11 | } -------------------------------------------------------------------------------- /TEST/x5.js: -------------------------------------------------------------------------------- 1 | const baseParse = _ => { 2 | let res = {}; 3 | let d = []; 4 | 5 | d.push({ 6 | desc: '96 && float', 7 | url: 'file:///storage/emulated/0/Android/data/com.example.hikerview/files/Documents/TyrantG/public/douyu-search.html?time='+(new Date()).getTime(), 8 | col_type:"x5_webview_single", 9 | }) 10 | 11 | res.data = d; 12 | setHomeResult(res); 13 | } -------------------------------------------------------------------------------- /TEXT/juejin.js: -------------------------------------------------------------------------------- 1 | js: 2 | addListener("onClose", $.toString(() => { 3 | clearItem('cate_level_1_id') 4 | clearItem('cate_level_2_id') 5 | clearItem('cursor') 6 | })) 7 | const d = [] 8 | const EMPTY = 'hiker://empty' 9 | const CATE_URL = 'https://juejin.cn' 10 | const SEC_CARE_API = 'https://api.juejin.cn/recommend_api/v1/tag/recommend_tag_list' 11 | const CONTENT_LIST_API = 'https://api.juejin.cn/recommend_api/v1/article/recommend_cate_tag_feed' 12 | const CURRENT_PAGE = MY_URL.split('##')[1].toString() 13 | const CATE_LEVEL_1_ID = getItem('cate_level_1_id', '') 14 | const CATE_LEVEL_2_ID = getItem('cate_level_2_id', '') 15 | 16 | const CATE_LEVEL_1_ARRAY = pdfa(fetch(CATE_URL, {headers: {"User-Agent": PC_UA}}), '.view-nav&&a') 17 | 18 | if (CURRENT_PAGE === '1') { 19 | clearItem('cursor') 20 | CATE_LEVEL_1_ARRAY.forEach(item => { 21 | let id = pdfh(item, '.category-popover-box&&st:state') || '' 22 | let title = pdfh(item, '.category-popover-box&&Text') 23 | 24 | d.push({ 25 | title: id === CATE_LEVEL_1_ID ? '‘‘’’'+title+'' : title, 26 | url: $(EMPTY).lazyRule(params => { 27 | setItem('cursor', '0') 28 | setItem('cate_level_1_id', params.id) 29 | setItem('cate_level_2_id', '') 30 | refreshPage(true) 31 | return 'hiker://empty' 32 | }, { 33 | id: id 34 | }), 35 | col_type: 'scroll_button' 36 | }) 37 | }) 38 | d.push({ 39 | col_type: "blank_block" 40 | }) 41 | 42 | if (CATE_LEVEL_1_ID) { 43 | d.push({ 44 | title: CATE_LEVEL_2_ID === '' ? '‘‘’’全部' : '全部', 45 | url: $(EMPTY).lazyRule(_ => { 46 | setItem('cate_level_2_id', '') 47 | refreshPage(true) 48 | return 'hiker://empty' 49 | }), 50 | col_type: 'scroll_button' 51 | }) 52 | let data = {"cate_id": CATE_LEVEL_1_ID} 53 | 54 | let headers = { 55 | "User-Agent": PC_UA, 56 | "Content-Type": 'application/json', 57 | "Referer": 'https://juejin.cn/', 58 | } 59 | const CATE_LEVEL_2_JSON = fetch(SEC_CARE_API, {headers: headers, method:'POST', body: JSON.stringify(data)}) 60 | const CATE_LEVEL_2_RESULT = JSON.parse(CATE_LEVEL_2_JSON) 61 | 62 | if (CATE_LEVEL_2_RESULT && CATE_LEVEL_2_RESULT.err_no === 0) { 63 | const CATE_LEVEL_2_ARRAY = CATE_LEVEL_2_RESULT.data 64 | CATE_LEVEL_2_ARRAY.forEach(item => { 65 | d.push({ 66 | title: CATE_LEVEL_2_ID === item.tag_id.toString() ? '‘‘’’'+item.tag_name+'' : item.tag_name, 67 | url: $(EMPTY).lazyRule(params => { 68 | setItem('cursor', '0') 69 | setItem('cate_level_2_id', params.id) 70 | refreshPage(true) 71 | return 'hiker://empty' 72 | }, { 73 | id: item.tag_id 74 | }), 75 | col_type: 'scroll_button' 76 | }) 77 | }) 78 | d.push({ 79 | col_type: "blank_block" 80 | }) 81 | } 82 | } 83 | } 84 | 85 | const CURSOR = getItem('cursor', '0') 86 | data = { 87 | cate_id: "6809637769959178254", 88 | cursor: CURSOR, 89 | id_type: 2, 90 | limit: 20, 91 | sort_type: 200, 92 | } 93 | if (CATE_LEVEL_1_ID) data.cate_id = CATE_LEVEL_1_ID 94 | if (CATE_LEVEL_2_ID) data.tag_id = CATE_LEVEL_2_ID 95 | 96 | headers = { 97 | "User-Agent": PC_UA, 98 | "Content-Type": 'application/json', 99 | "Referer": 'https://juejin.cn/', 100 | } 101 | const LIST_JSON = fetch(CONTENT_LIST_API, {headers: headers, method:'POST', body: JSON.stringify(data)}) 102 | const LIST_RESULT = JSON.parse(LIST_JSON) 103 | 104 | if (LIST_RESULT && LIST_RESULT.err_no === 0) { 105 | setItem('cursor', LIST_RESULT.cursor) 106 | const LIST = LIST_RESULT.data 107 | LIST.forEach(item => { 108 | d.push({ 109 | title: item.article_info.title, 110 | desc: item.article_info.brief_content, 111 | pic_url: item.article_info.cover_image, 112 | url: $(CATE_URL+'/post/'+item.article_id).rule(_ => { 113 | const d = [] 114 | const html = fetch(MY_URL, {headers: {"User-Agent": PC_UA}}) 115 | const data_json = html.match(/{layout(.*?)globalRefs:{}}/) 116 | let a,b,c,e,f,g,h,i,j,k,l,m,n,o,p,q,r,s,t,u,v,w,x,y,z,A,B,C,D = {} 117 | let data = {} 118 | eval('data = '+data_json[0]) 119 | d.push({ 120 | title: data.state.view.column.entry.content, 121 | col_type: 'rich_text', 122 | }) 123 | 124 | setResult(d) 125 | }), 126 | col_type: 'movie_1' 127 | }) 128 | }) 129 | } 130 | 131 | setResult(d) 132 | -------------------------------------------------------------------------------- /TOOL/aktools.js: -------------------------------------------------------------------------------- 1 | const baseParse = _ => { 2 | let res = {}; 3 | let d = []; 4 | 5 | d.push({ 6 | desc: '100% && float', 7 | url: "https://www.bigfun.cn/tools/aktools/", 8 | col_type: 'x5_webview_single' 9 | }); 10 | 11 | res.data = d; 12 | setHomeResult(res); 13 | } -------------------------------------------------------------------------------- /TOOL/bailan_paste.js: -------------------------------------------------------------------------------- 1 | js: 2 | addListener("onRefresh", $.toString(() => { 3 | clearVar('cate'); 4 | clearVar('content'); 5 | clearVar('password'); 6 | clearVar('time_limit'); 7 | })) 8 | let d = []; 9 | const cate = getItem('cate', '1') 10 | d.push({ 11 | title: cate === '1' ? '‘‘’’导入' : '导入', 12 | url: $().lazyRule(_ => { 13 | setItem('cate', '1') 14 | refreshPage(true) 15 | return "hiker://empty" 16 | }), 17 | col_type: 'scroll_button' 18 | }) 19 | d.push({ 20 | title: cate === '2' ? '‘‘’’创建' : '创建', 21 | url: $().lazyRule(_ => { 22 | setItem('cate', '2') 23 | refreshPage(true) 24 | return "hiker://empty" 25 | }), 26 | col_type: 'scroll_button' 27 | }) 28 | 29 | if (cate === '1') { 30 | d.push({ 31 | title: '导入', 32 | desc: '请粘贴内容', 33 | col_type: 'input', 34 | url: $.toString(() => { 35 | const res = input.split(' ') 36 | let path, password 37 | if (res.length === 2) { 38 | path = res[0].split('/').pop() 39 | password = res[1] 40 | } else { 41 | path = res[0].split('/').pop() 42 | } 43 | 44 | const json = request("https://pasteme.tyrantg.com/api/getContent/"+path+'@'+password) 45 | const result = JSON.parse(json) 46 | 47 | if (result.return_code !== 0) { 48 | log(result) 49 | refreshPage(true) 50 | return "toast://"+result.message 51 | } 52 | 53 | result.data = decodeURIComponent(result.data) 54 | if (result.data.startsWith('海阔视界')) 55 | return result.data 56 | else 57 | return "copy://"+result.data 58 | }) 59 | }) 60 | } else if (cate === '2') { 61 | d.push({ 62 | title: '', 63 | desc: '请输入内容', 64 | col_type: 'input', 65 | extra: { 66 | type: 'textarea', 67 | titleVisible: false, 68 | height: 3, 69 | onChange: $.toString(_ => { 70 | setItem('content', input.trim()) 71 | }) 72 | } 73 | }) 74 | d.push({ 75 | title: '', 76 | desc: '请输入自定义密码(不输入会自动生成)', 77 | col_type: 'input', 78 | extra: { 79 | titleVisible: false, 80 | onChange: $.toString(_ => { 81 | setItem('password', input.trim()) 82 | }) 83 | } 84 | }) 85 | d.push({ 86 | title: '', 87 | desc: '请输入限制时间(分钟)', 88 | col_type: 'input', 89 | extra: { 90 | titleVisible: false, 91 | onChange: $.toString(_ => { 92 | setItem('time_limit', input.trim()) 93 | }) 94 | } 95 | }) 96 | d.push({ 97 | col_type: 'line_blank' 98 | }) 99 | d.push({ 100 | title: '提交', 101 | col_type: 'text_center_1', 102 | url: $().lazyRule(_ => { 103 | const obj2strUrl = (obj) => { 104 | let str=""; 105 | for (let key in obj) { 106 | str += key+'='+encodeURIComponent(obj[key])+'&' 107 | } 108 | str = str.substring(0, str.length-1); 109 | return str; 110 | } 111 | const param_body = {} 112 | const content = getItem('content', '') 113 | const password = getItem('password', '') 114 | const time_limit = getItem('time_limit', '') 115 | 116 | if (content === '') { 117 | refreshPage(true) 118 | return "toast://请输入内容" 119 | } 120 | param_body.content = content 121 | 122 | if (password !== '') 123 | param_body.password = password 124 | else 125 | param_body.auto_password = 1 126 | 127 | if (time_limit !== '') param_body.time_limit = time_limit 128 | 129 | const json = request("https://pasteme.tyrantg.com/api/create", {body: obj2strUrl(param_body), method:'POST'}) 130 | const res = JSON.parse(json) 131 | 132 | if (res.return_code !== 0) { 133 | log(res) 134 | refreshPage(true) 135 | return "toast://"+res.message 136 | } 137 | 138 | let result = "https://pasteme.tyrantg.com/"+res.data.path 139 | 140 | if (res.data.password) result += ' '+res.data.password 141 | 142 | copy(result) 143 | refreshPage(true) 144 | return "toast://已复制到剪贴板" 145 | }) 146 | }) 147 | } 148 | 149 | setResult(d) -------------------------------------------------------------------------------- /TOOL/bt.js: -------------------------------------------------------------------------------- 1 | const bt = { 2 | BaseUrl: "http://172.67.7.24/", 3 | empty: 'hiker://empty', 4 | picacg_path: "hiker://files/rules/js/TyrantGenesis_哔咔设置.js", 5 | searchHistory: "hiker://files/rules/js/TyrantGenesis_哔咔搜索历史.js", 6 | apiKey: "C69BAF41DA5ABD1FFEDC6D2FEA56B", 7 | nonce: "b1ab87b4800d4d4590a11701b8551afa", 8 | secretKey: "~d}$Q7$eIni=V)9\\RK/P.RM4;9[7|@/CA}b~OW!3?EV`:<>M7pddUBL5n|0/*Cn", 9 | d: [], 10 | } -------------------------------------------------------------------------------- /TOOL/cloud-music.js: -------------------------------------------------------------------------------- 1 | const baseParse = _ => { 2 | let res = {}; 3 | let d = []; 4 | 5 | d.push({ 6 | title: '我的歌单', 7 | pic_url: "https://git.tyrantg.com/tyrantgenesis/hikerViewRules/raw/master/assets/icons/list.png", 8 | url: $("hiker://empty").lazyRule(_ => { 9 | refreshPage() 10 | return input 11 | }), 12 | col_type: 'icon_round_4' 13 | }); 14 | d.push({ 15 | title: '搜索', 16 | pic_url: "https://git.tyrantg.com/tyrantgenesis/hikerViewRules/raw/master/assets/icons/search.png", 17 | col_type: 'icon_round_4' 18 | }); 19 | d.push({ 20 | title: '导入', 21 | pic_url: "https://git.tyrantg.com/tyrantgenesis/hikerViewRules/raw/master/assets/icons/turn.png", 22 | col_type: 'icon_round_4' 23 | }); 24 | d.push({ 25 | title: '设置', 26 | pic_url: "https://git.tyrantg.com/tyrantgenesis/hikerViewRules/raw/master/assets/icons/setting.png", 27 | col_type: 'icon_round_4' 28 | }); 29 | 30 | const list_json = request("hiker://files/TyrantG/data/music_list.json") 31 | const list = JSON.parse(list_json) 32 | 33 | list.forEach(item => { 34 | d.push({ 35 | title: item.name, 36 | desc: item.desc, 37 | pic_url: item.cover_image, 38 | url: $("hiker://empty").rule(param => { 39 | let d = []; 40 | const list = param.list 41 | list.forEach(music => { 42 | d.push({ 43 | title: music.name, 44 | desc: music.author, 45 | url: music.url, 46 | pic_url: music.cover_image, 47 | }) 48 | }) 49 | 50 | setResult(d); 51 | }, {list: item.list}), 52 | col_type: 'movie_1_vertical_pic' 53 | }); 54 | }) 55 | 56 | res.data = d; 57 | setHomeResult(res); 58 | } 59 | 60 | const secParse = _ => { 61 | let res = {}; 62 | let d = []; 63 | 64 | 65 | res.data = d; 66 | setHomeResult(res); 67 | } -------------------------------------------------------------------------------- /TOOL/prts.js: -------------------------------------------------------------------------------- 1 | const baseParse = _ => { 2 | let res = {}; 3 | let d = []; 4 | 5 | d.push({ 6 | desc: '100% && float', 7 | url: "http://prts.wiki/w/%E9%A6%96%E9%A1%B5", 8 | col_type: 'x5_webview_single' 9 | }); 10 | 11 | res.data = d; 12 | setHomeResult(res); 13 | } -------------------------------------------------------------------------------- /TOOL/ys_map.js: -------------------------------------------------------------------------------- 1 | const baseParse = _ => { 2 | let res = {}; 3 | let d = []; 4 | 5 | d.push({ 6 | desc: '100% && float', 7 | url: "https://static-web.ghzs.com/cspage_pro/yuanshenMap.html#/", 8 | col_type: 'x5_webview_single' 9 | }); 10 | 11 | res.data = d; 12 | setHomeResult(res); 13 | } -------------------------------------------------------------------------------- /TOOL/zczc.js: -------------------------------------------------------------------------------- 1 | const baseParse = _ => { 2 | let d = []; 3 | const script = fetch("https://cdn.jsdelivr.net/npm/dos.zczc.cz_vue@2.3.0/dist/js/app.cf392961.js") 4 | const match = script.match(/a301\:.*,b479/)[0] 5 | const js = match.replace('a301:function(e){e.exports=', 'const json = ').replace('},b479', '') 6 | eval(js) 7 | for (let j in json) { 8 | d.push({ 9 | title: j, 10 | // desc: parseDomForHtml(list[j], '.mvhdico&&Text'), 11 | pic_url: "https://cdn.jsdelivr.net/npm/dos.zczc.cz_vue/dist/static/games/img/"+j+"/"+json[j].coverFilename, 12 | url: $("https://dos.zczc.cz/games/"+j+"").rule(_ => { 13 | let res = {}; 14 | let d = []; 15 | 16 | d.push({ 17 | desc: '100% && float', 18 | url: MY_URL, 19 | col_type: 'x5_webview_single' 20 | }); 21 | 22 | res.data = d; 23 | setHomeResult(res); 24 | }) 25 | }); 26 | } 27 | 28 | setResult(d); 29 | } -------------------------------------------------------------------------------- /VIDEO/400.js: -------------------------------------------------------------------------------- 1 | const baseParse = _ => { 2 | let d = [] 3 | let [url, page] = MY_URL.split('##') 4 | const class_url = getMyVar('400.tyrantgenesis.class_url') 5 | if (class_url !== MY_RULE.class_url) { 6 | clearMyVar('400.tyrantgenesis.url') 7 | putMyVar('400.tyrantgenesis.class_url', MY_RULE.class_url) 8 | } 9 | 10 | url = getMyVar('400.tyrantgenesis.url', url) 11 | url = url.replace('.html', '-'+page+'.html') 12 | const html = fetch(url) 13 | 14 | if (parseInt(page) === 1) { 15 | const category = pdfa(html, '.gm-meta&&a') 16 | category.forEach(cate => { 17 | let className = pdfh(cate, 'a&&class') 18 | let title = pdfh(cate, 'a&&Text') 19 | d.push({ 20 | title: className === 'on' ? '““””'+title+"" : title, 21 | url: $(pd(cate, 'a&&href')).lazyRule(() => { 22 | putMyVar('400.tyrantgenesis.url', input) 23 | refreshPage(true) 24 | return "hiker://empty" 25 | }), 26 | col_type: 'scroll_button', 27 | }) 28 | }) 29 | 30 | d.push({ 31 | col_type:"blank_block" 32 | }) 33 | } 34 | 35 | const list = pdfa(html, '.gm-list&&.item') 36 | 37 | list.forEach(item => { 38 | let pic_url = pdfh(item, 'img&&data-src') 39 | d.push({ 40 | title: pdfh(item, '.info&&.title&&Text'), 41 | desc: pdfh(item, '.tag2&&Text'), 42 | pic_url: pic_url.startsWith('http') ? pic_url : 'https:'+pic_url, 43 | url: pd(item, '.title&&href')+'#immersiveTheme#', 44 | col_type: 'movie_3_marquee', 45 | }) 46 | }) 47 | 48 | setResult(d); 49 | } 50 | 51 | const secParse = _ => { 52 | let d = []; 53 | const html = getResCode() 54 | const video_info = pdfh(html, '.gm-vod&&Html') 55 | const video_content = pdfa(video_info, '.more&&.info') 56 | 57 | d.push( 58 | { 59 | title: video_content.filter((item, index) => index < 3).map(item => pdfh(item, '.info&&Text')).join('\n'), 60 | desc: pdfh(video_content[video_content.length - 1], '.info&&Text'), 61 | url: MY_URL, 62 | pic_url: pd(video_info, 'img&&src'), 63 | col_type: 'movie_1_vertical_pic_blur', 64 | }, 65 | { 66 | col_type: 'line_blank' 67 | }, 68 | ) 69 | 70 | const video_source_json = html.match(/var post = (.*?);/)[1] 71 | const video_source = JSON.parse(video_source_json).vods 72 | video_source.forEach(source => { 73 | let list = source.source 74 | d.push({ 75 | title: source.name, 76 | url: list[0][1], 77 | pic_url: 'https://lanmeiguojiang.com/tubiao/movie/6.svg', 78 | col_type: 'avatar', 79 | }) 80 | list.forEach(item => { 81 | d.push({ 82 | title: item[0], 83 | url: item[1], 84 | col_type: 'text_3', 85 | }) 86 | }) 87 | d.push({ 88 | col_type: 'line' 89 | }) 90 | }) 91 | 92 | setResult(d); 93 | } 94 | -------------------------------------------------------------------------------- /VIDEO/4kvm.js: -------------------------------------------------------------------------------- 1 | const baseParse = _ => { 2 | let d = []; 3 | const cate = MY_URL.split('####')[1] 4 | 5 | const temp1 = _ => { 6 | let list = parseDomForArray(getResCode(), '#archive-content&&.item') 7 | list.forEach(item => { 8 | d.push({ 9 | title: parseDomForHtml(item, 'h3&&Text'), 10 | pic_url: parseDomForHtml(item, 'img&&src'), 11 | url: parseDomForHtml(item, 'a&&href')+'#immersiveTheme#', 12 | desc: parseDomForHtml(item, '.rating&&Text'), 13 | }) 14 | }) 15 | } 16 | 17 | const temp2 = _ => { 18 | let list = parseDomForArray(getResCode(), '.items&&.item') 19 | list.forEach(item => { 20 | d.push({ 21 | title: parseDomForHtml(item, 'h3&&Text'), 22 | pic_url: parseDomForHtml(item, 'img&&src'), 23 | url: parseDomForHtml(item, 'a&&href')+'#immersiveTheme#', 24 | desc: parseDomForHtml(item, '.rating&&Text'), 25 | }) 26 | }) 27 | } 28 | 29 | switch (cate) { 30 | case 'movies': 31 | temp1() 32 | break 33 | default: 34 | temp2() 35 | } 36 | 37 | setResult(d); 38 | } 39 | 40 | const secParse = _ => { 41 | let d = []; 42 | let header = parseDomForHtml(getResCode(), '.sheader&&Html') 43 | 44 | d.push({ 45 | title: parseDomForHtml(header, 'h1&&Text'), 46 | pic_url: parseDomForHtml(header, 'img&&src'), 47 | url: MY_URL, 48 | desc: parseDomForHtml(getResCode(), '.wp-content&&p&&Text'), 49 | }) 50 | d.push({ 51 | col_type: 'line' 52 | }) 53 | 54 | let list = parseDomForArray(getResCode(), '#episodes&&.se-c') 55 | 56 | d.push({ 57 | title: '选集', 58 | url: "hiker://empty", 59 | col_type: 'text_1', 60 | }) 61 | if (list.length > 0) { 62 | list.forEach(item => { 63 | d.push({ 64 | title: parseDomForHtml(item, '.title&&Text'), 65 | url: "hiker://empty", 66 | col_type: 'text_1', 67 | }) 68 | let current_list = parseDomForArray(item, 'ul&&li') 69 | if (current_list.length > 0) { 70 | current_list.reverse().forEach(data => { 71 | d.push({ 72 | title: parseDomForHtml(data, 'a&&Text').replace(' ', ''), 73 | url: $(parseDomForHtml(data, 'a&&href')).lazyRule(_ => { 74 | let video = parseDomForArray(request(input), '#playeroptionsul&&li')[0] 75 | let fetch = request("https://www.4kvm.com/wp-json/dooplayer/v1/post/"+parseDomForHtml(video, 'li&&data-post')+"?type=movie&source=1") 76 | return "http://4kjx.dev.tyrantg.com/index.m3u8?url="+encodeURIComponent(JSON.parse(fetch).embed_url)+'#isVideo=true#' 77 | }), 78 | col_type: 'text_4', 79 | }) 80 | }) 81 | } else { 82 | let html = request(parseDomForHtml(item, 'a&&href')) 83 | let sel_list_json = html.match(/videourls:\[(.*?)],/)[1] 84 | let sel_list = JSON.parse(sel_list_json) 85 | sel_list.forEach(data => { 86 | d.push({ 87 | title: "第"+data.name+"集", 88 | url: "http://4kjx.dev.tyrantg.com/index.m3u8?url="+encodeURIComponent(data.url)+'#isVideo=true#', 89 | col_type: 'text_4', 90 | }) 91 | }) 92 | } 93 | }) 94 | } else { 95 | let video = parseDomForArray(getResCode(), '#playeroptionsul&&li') 96 | video.forEach(item => { 97 | d.push({ 98 | title: parseDomForHtml(item, '.title&&Text'), 99 | url: $("https://www.4kvm.com/wp-json/dooplayer/v1/post/"+parseDomForHtml(item, 'li&&data-post')+"?type=movie&source=1").lazyRule(_ => { 100 | let fetch = request(input) 101 | return "http://4kjx.dev.tyrantg.com/index.m3u8?url="+encodeURIComponent(JSON.parse(fetch).embed_url)+'#isVideo=true#' 102 | }), 103 | col_type: 'text_2', 104 | }) 105 | }) 106 | 107 | } 108 | 109 | setResult(d); 110 | } 111 | -------------------------------------------------------------------------------- /VIDEO/555dy.js: -------------------------------------------------------------------------------- 1 | const DY5 = { 2 | name: '555电影', 3 | empty: 'hiker://empty', 4 | baseUrl: 'https://www.555dy.fun', 5 | dom: [], 6 | category: [ 7 | { 8 | type: 'vodtype', 9 | name: '电影', 10 | url: '/vodshow/1-----------.html', 11 | }, 12 | { 13 | type: 'vodtype', 14 | name: '连续剧', 15 | url: '/vodshow/2-----------.html', 16 | }, 17 | { 18 | type: 'vodtype', 19 | name: '综艺纪录', 20 | url: '/vodshow/3-----------.html', 21 | }, 22 | { 23 | type: 'vodtype', 24 | name: '动漫', 25 | url: '/vodshow/4-----------.html', 26 | }, 27 | { 28 | type: 'label', 29 | subType: 'week', 30 | name: '追剧周表', 31 | url: '/label/week.html', 32 | }, 33 | { 34 | type: 'label', 35 | subType: 'new', 36 | name: '今日更新', 37 | url: '/label/new.html', 38 | }, 39 | { 40 | type: 'label', 41 | subType: 'topic', 42 | name: '专题列表', 43 | url: '/label/topic.html', 44 | }, 45 | ], 46 | categorySelect: getItem('categorySelect', '0'), 47 | baseParse: () => { 48 | const page = parseInt(MY_URL.split('##')[1]) 49 | const currentCategoryItem = DY5.category[parseInt(DY5.categorySelect)] 50 | if (page === 1) { 51 | DY5.categoryParse() 52 | if (currentCategoryItem.type === 'vodtype') { 53 | DY5.vodTypeCateParse(currentCategoryItem) 54 | } 55 | } 56 | setResult(DY5.dom) 57 | }, 58 | categoryParse: () => { 59 | DY5.category.forEach((item, index) => { 60 | DY5.dom.push({ 61 | title: parseInt(DY5.categorySelect) === index ? '‘‘’’'+item.name+'' : item.name, 62 | url: $(DY5.empty).lazyRule((index) => { 63 | setItem('categorySelect', index) 64 | refreshPage(false) 65 | return 'hiker://empty' 66 | }, index.toString()), 67 | col_type: 'scroll_button', 68 | }) 69 | }) 70 | }, 71 | vodTypeCateParse: (currentCategoryItem) => { 72 | 73 | }, 74 | } 75 | 76 | $.exports = DY5 77 | -------------------------------------------------------------------------------- /VIDEO/OneList.js: -------------------------------------------------------------------------------- 1 | const empty = 'hiker://empty' 2 | 3 | const baseParse = () => { 4 | let d = [] 5 | const json = getResCode() 6 | const list = JSON.parse(json).data 7 | 8 | list.forEach(item => { 9 | d.push({ 10 | title: item.title, 11 | desc: item.score+'分', 12 | pic_url: item.image, 13 | url: $(empty+'#immersiveTheme#').rule((id) => { 14 | require('hiker://page/one') 15 | secParse(id) 16 | }, item.ID), 17 | }) 18 | }) 19 | 20 | setResult(d) 21 | } 22 | 23 | const secParse = (id) => { 24 | let d = [] 25 | const url = 'https://onelist.top/v1/api/video/id?id='+id 26 | const json = fetch(url, {headers:{},method:'POST'}) 27 | const data = JSON.parse(json).data 28 | 29 | const list = data.url_content.split("\n") 30 | 31 | d.push({ 32 | title: '主演:'+data.authors, 33 | desc: '简介:'+data.content, 34 | pic_url: data.image, 35 | url: 'https://onelist.top/detail?id='+id, 36 | col_type: 'movie_1_vertical_pic_blur', 37 | }) 38 | 39 | d.push({ 40 | title: '选集', 41 | url: "hiker://empty", 42 | col_type: 'text_1', 43 | }) 44 | 45 | list.forEach((item, index) => { 46 | d.push({ 47 | title: '第'+(index+1)+'集', 48 | url: item.split('$')[1], 49 | col_type: 'text_4', 50 | }) 51 | }) 52 | 53 | setResult(d) 54 | } 55 | -------------------------------------------------------------------------------- /VIDEO/douyin_slide.js: -------------------------------------------------------------------------------- 1 | js: 2 | const douyin_cookie = "hiker://files/TyrantG/cookie/douyin.txt" 3 | const slide_cookie = "hiker://files/TyrantG/cookie/douyin_slide.txt" 4 | 5 | const baseParse = _ => { 6 | let d = [], category, html 7 | let home_cookie = request(douyin_cookie) 8 | let slide_d_cookie = request(slide_cookie) 9 | const empty = "hiker://empty" 10 | html = fetch("https://www.douyin.com", {headers:{"User-Agent": PC_UA, "cookie": home_cookie+slide_d_cookie}, withHeaders: true}) 11 | html = JSON.parse(html) 12 | 13 | // 滑块验证 14 | if (! slide_d_cookie || html.body.match(/验证码/)) { 15 | confirm( 16 | { 17 | title:'滑块验证', 18 | content:'检测到需要通过滑块验证', 19 | confirm: $.toString(_ => { 20 | const slide_cookie = "hiker://files/TyrantG/cookie/douyin_slide.txt" 21 | showLoading('自动验证中') 22 | let slide_d_cookie = fetch("http://douyin_signature.dev.tyrantg.com/slide.php", {timeout: 30000}) 23 | if(slide_d_cookie) writeFile(slide_cookie, slide_d_cookie) 24 | hideLoading() 25 | refreshPage(true) 26 | }), 27 | cancel:'refreshPage(true)' 28 | } 29 | ) 30 | 31 | }else { 32 | // 首页cookie 33 | if (! home_cookie || ! home_cookie.match(/ttwid=/) || html.body.match(/<\/body>/)) { 34 | let cookie = html.headers["set-cookie"] 35 | if(cookie) { 36 | home_cookie = html.headers["set-cookie"][0].split(';')[0] + ';' 37 | writeFile(douyin_cookie, request(douyin_cookie)+home_cookie) 38 | } else { 39 | //log(html) 40 | } 41 | refreshPage(true) 42 | } else { 43 | let current_page = MY_URL.split('##')[1].toString() 44 | 45 | let cate_select = getVar("tyrantgenesis.simple_douyin_web.cate_select", "") 46 | 47 | if (current_page === '1') { 48 | category = [ 49 | {title: '全部', id: ''}, 50 | {title: '娱乐', id: '300201'}, 51 | {title: '知识', id: '300203'}, 52 | {title: '二次元', id: '300206'}, 53 | {title: '游戏', id: '300205'}, 54 | {title: '美食', id: '300204'}, 55 | {title: '体育', id: '300207'}, 56 | {title: '时尚', id: '300208'}, 57 | {title: '音乐', id: '300209'}, 58 | ] 59 | category.forEach(cate => { 60 | d.push({ 61 | title: cate_select === cate.id ? '‘‘’’'+cate.title+'' : cate.title, 62 | url: $(empty).lazyRule(params => { 63 | putVar("tyrantgenesis.simple_douyin_web.cate_select", params.id) 64 | refreshPage(false) 65 | return "hiker://empty" 66 | }, { 67 | id: cate.id 68 | }), 69 | col_type: 'scroll_button', 70 | }) 71 | }) 72 | } 73 | 74 | // let not_sign_url = "https://www.douyin.com/aweme/v1/web/channel/feed/?device_platform=webapp&aid=6383&channel=channel_pc_web&tag_id="+cate_select+"&count=20&version_code=160100&version_name=16.1.0" 75 | 76 | let sign_url = fetch("http://douyin_signature.dev.tyrantg.com?type=feed¶ms="+cate_select) 77 | // let true_url = not_sign_url + "&_signature="+sign 78 | let data_json = fetch(sign_url, { 79 | headers: { 80 | "referer" : "https://www.douyin.com/", 81 | "cookie": home_cookie+slide_d_cookie, 82 | } 83 | }) 84 | 85 | if (! data_json || data_json === 'Need Verifying') { 86 | d.push({ 87 | title: 'signature 获取失败,待修复', 88 | col_type: "long_text", 89 | }) 90 | } else { 91 | let list = JSON.parse(data_json).aweme_list 92 | if (list && list.length > 0) { 93 | list.forEach(item => { 94 | if (item.video && item.author) { 95 | d.push({ 96 | title: item.desc, 97 | pic_url: item.video.cover.url_list[0], 98 | desc: item.author.nickname, 99 | url: $(empty).lazyRule(item => { 100 | return item.video.play_addr.url_list[0] + "#isVideo=true#" 101 | }, item), 102 | col_type: 'movie_2', 103 | }) 104 | } else { 105 | //item.cell_room.rawdata.replace(/:([1-9]\d*),/g, ':"$1",') 106 | } 107 | }) 108 | } 109 | } 110 | setResult(d); 111 | } 112 | } 113 | } 114 | baseParse() -------------------------------------------------------------------------------- /VIDEO/simple_douyin_web.js: -------------------------------------------------------------------------------- 1 | js: 2 | const douyin_cookie = "hiker://files/TyrantG/cookie/douyin.txt" 3 | // const slide_cookie = "hiker://files/TyrantG/cookie/douyin_slide.txt" 4 | 5 | const baseParse = _ => { 6 | let d = [], category, html 7 | let home_cookie = request(douyin_cookie) 8 | // let slide_d_cookie = request(slide_cookie) 9 | const empty = "hiker://empty" 10 | html = fetch("https://www.douyin.com", {headers:{"User-Agent": PC_UA, "cookie": home_cookie}, withHeaders: true}) 11 | html = JSON.parse(html) 12 | 13 | // 首页cookie 14 | if (! home_cookie || ! home_cookie.match(/__ac_nonce/) || html.body.match(/<\/body>/)) { 15 | let cookie = html.headers["set-cookie"].join(';') 16 | 17 | writeFile(douyin_cookie, cookie.match(/__ac_nonce=(.*?);/)[0]) 18 | } 19 | 20 | // 滑块验证 21 | if (html.body.match(/验证码/)) { 22 | d.push({ 23 | title: '本地cookie失效, 请点击获取(需要过验证,15秒左右)', 24 | url: $(empty).lazyRule(_ => { 25 | const douyin_cookie = "hiker://files/TyrantG/cookie/douyin.txt" 26 | let current_cookie = request(douyin_cookie).match(/__ac_nonce=(.*?);/)[0] 27 | showLoading('自动验证中') 28 | let slide_cookie = fetch("http://student.tyrantg.com:8199/slide.php", {timeout: 30000}) 29 | if(slide_cookie) writeFile(douyin_cookie, current_cookie+slide_cookie) 30 | hideLoading() 31 | refreshPage(true) 32 | return 'toast://验证成功' 33 | }), 34 | col_type: 'text_1' 35 | }) 36 | } else { 37 | 38 | let current_page = MY_URL.split('##')[1].toString() 39 | 40 | let cate_select = getVar("tyrantgenesis.simple_douyin_web.cate_select", "") 41 | 42 | if (current_page === '1') { 43 | category = [ 44 | {title: '全部', id: ''}, 45 | {title: '娱乐', id: '300201'}, 46 | {title: '知识', id: '300203'}, 47 | {title: '二次元', id: '300206'}, 48 | {title: '游戏', id: '300205'}, 49 | {title: '美食', id: '300204'}, 50 | {title: '体育', id: '300207'}, 51 | {title: '时尚', id: '300208'}, 52 | {title: '音乐', id: '300209'}, 53 | ] 54 | category.forEach(cate => { 55 | d.push({ 56 | title: cate_select === cate.id ? '‘‘’’'+cate.title+'' : cate.title, 57 | url: $(empty).lazyRule(params => { 58 | putVar("tyrantgenesis.simple_douyin_web.cate_select", params.id) 59 | refreshPage(false) 60 | return "hiker://empty" 61 | }, { 62 | id: cate.id 63 | }), 64 | col_type: 'scroll_button', 65 | }) 66 | }) 67 | } 68 | 69 | // let not_sign_url = "https://www.douyin.com/aweme/v1/web/channel/feed/?device_platform=webapp&aid=6383&channel=channel_pc_web&tag_id="+cate_select+"&count=20&version_code=160100&version_name=16.1.0" 70 | 71 | let sign_url = fetch("http://douyin_signature.dev.tyrantg.com?type=feed¶ms="+cate_select) 72 | // let true_url = not_sign_url + "&_signature="+sign 73 | let data_json = fetch(sign_url, { 74 | headers: { 75 | "referer" : "https://www.douyin.com/", 76 | "cookie": home_cookie, 77 | "Accept": 'application/json, text/plain, */*', 78 | "User-Agent": PC_UA, 79 | "Accept-Language": 'zh-CN,zh;q=0.9', 80 | } 81 | }) 82 | 83 | if (! data_json || data_json === 'Need Verifying') { 84 | d.push({ 85 | title: 'signature 获取失败,待修复', 86 | col_type: "long_text", 87 | }) 88 | } else { 89 | let list = JSON.parse(data_json).aweme_list 90 | if (list && list.length > 0) { 91 | list.forEach(item => { 92 | if (item.video && item.author) { 93 | d.push({ 94 | title: item.desc, 95 | pic_url: item.video.cover.url_list[0], 96 | desc: item.author.nickname, 97 | url: $(empty).lazyRule(item => { 98 | return item.video.play_addr.url_list[0] + "#isVideo=true#" 99 | }, item), 100 | col_type: 'movie_2', 101 | }) 102 | } else { 103 | //item.cell_room.rawdata.replace(/:([1-9]\d*),/g, ':"$1",') 104 | } 105 | }) 106 | } 107 | } 108 | } 109 | setResult(d); 110 | } 111 | baseParse() 112 | -------------------------------------------------------------------------------- /VIDEO/youtube.js: -------------------------------------------------------------------------------- 1 | const youtube = { 2 | name: 'YouTube', 3 | empty: 'hiker://empty', 4 | d: [], 5 | plugins: { 6 | channels: "hiker://files/rules/js/TyrantGenesis_YouTube-Channels.js", 7 | keyPath: "hiker://files/rules/js/TyrantGenesis_YouTube-api-key.js", 8 | }, 9 | defaultChannels: [ 10 | { 11 | title: 'J. Cole', 12 | channelId: 'UCnc6db-y3IU7CkT_yeVXdVg', 13 | icon: 'https://yt3.ggpht.com/ytc/AAUvwniDYxWC2x4VZF7ecutGEaLpssNmrptdeuVFJI999g=s88-c-k-c0x00ffffff-no-rj-mo', 14 | }, 15 | { 16 | title: 'Lofi Girl', 17 | channelId: 'UCSJ4gkVC6NrvII8umztf0Ow', 18 | icon: 'https://yt3.ggpht.com/ytc/AAUvwnhGIymQGp3jRMECbTCBSRAUqi8sKbATpWowQG44CA=s88-c-k-c0x00ffffff-no-rj', 19 | }, 20 | { 21 | title: 'HatsuneMiku', 22 | channelId: 'UCJwGWV914kBlV4dKRn7AEFA', 23 | icon: 'https://yt3.ggpht.com/ytc/AAUvwnjlsiW6yKsmkrfqn2foSm-ONTTWLeK_G70PF6TXBg=s800-c-k-c0x00ffffff-no-rj-mo', 24 | } 25 | ], 26 | defaultKey: 'AIzaSyDAVB60lCVpHO0nnsWyGtDWC9DTxH8vWlg', 27 | channelSelect: setItem('YouTube.channelSelect', '0'), 28 | homePageToken: setItem('YouTube.homePageToken', ''), 29 | pluginsInit: () => { 30 | const channels = fetch(youtube.plugins.channels) 31 | const key = fetch(youtube.plugins.keyPath) 32 | if (! channels) { 33 | const defaultChannels = youtube.defaultChannels.map(channel => channel.title+'$$$'+channel.channelId+'$$$'+channel.icon).join('\n') 34 | writeFile(youtube.plugins.channels, defaultChannels) 35 | } 36 | if (! key) { 37 | writeFile(youtube.plugins.keyPath, youtube.defaultKey) 38 | } 39 | }, 40 | baseParse: () => { 41 | setResult(youtube.d) 42 | }, 43 | } 44 | 45 | $.exports = youtube 46 | -------------------------------------------------------------------------------- /assets/icons/list.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/TyrantG/hikerViewRules/5156f21468352dc92d934393f125a2f2d31c469e/assets/icons/list.png -------------------------------------------------------------------------------- /assets/icons/ps4.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /assets/icons/search.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/TyrantG/hikerViewRules/5156f21468352dc92d934393f125a2f2d31c469e/assets/icons/search.png -------------------------------------------------------------------------------- /assets/icons/setting.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/TyrantG/hikerViewRules/5156f21468352dc92d934393f125a2f2d31c469e/assets/icons/setting.png -------------------------------------------------------------------------------- /assets/icons/sort-ascending.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/TyrantG/hikerViewRules/5156f21468352dc92d934393f125a2f2d31c469e/assets/icons/sort-ascending.png -------------------------------------------------------------------------------- /assets/icons/sort-descending.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/TyrantG/hikerViewRules/5156f21468352dc92d934393f125a2f2d31c469e/assets/icons/sort-descending.png -------------------------------------------------------------------------------- /assets/icons/steam.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /assets/icons/switch.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /assets/icons/turn.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/TyrantG/hikerViewRules/5156f21468352dc92d934393f125a2f2d31c469e/assets/icons/turn.png -------------------------------------------------------------------------------- /assets/icons/xboxone.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /assets/icons/专题.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /assets/icons/关注.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /assets/icons/播单.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /assets/icons/收藏.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /assets/icons/文章.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /assets/icons/游戏.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /assets/icons/电台.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /assets/icons/视频.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /assets/icons/设置.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /assets/icons/资讯.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /assets/images/4k.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/TyrantG/hikerViewRules/5156f21468352dc92d934393f125a2f2d31c469e/assets/images/4k.png -------------------------------------------------------------------------------- /assets/images/avatar-r.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/TyrantG/hikerViewRules/5156f21468352dc92d934393f125a2f2d31c469e/assets/images/avatar-r.png -------------------------------------------------------------------------------- /assets/images/avatar.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/TyrantG/hikerViewRules/5156f21468352dc92d934393f125a2f2d31c469e/assets/images/avatar.jpg -------------------------------------------------------------------------------- /assets/images/chuzhan.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/TyrantG/hikerViewRules/5156f21468352dc92d934393f125a2f2d31c469e/assets/images/chuzhan.png -------------------------------------------------------------------------------- /assets/images/douyin.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/TyrantG/hikerViewRules/5156f21468352dc92d934393f125a2f2d31c469e/assets/images/douyin.jpg -------------------------------------------------------------------------------- /assets/images/douyu.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/TyrantG/hikerViewRules/5156f21468352dc92d934393f125a2f2d31c469e/assets/images/douyu.png -------------------------------------------------------------------------------- /assets/images/huya.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/TyrantG/hikerViewRules/5156f21468352dc92d934393f125a2f2d31c469e/assets/images/huya.png -------------------------------------------------------------------------------- /assets/images/juejin.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/TyrantG/hikerViewRules/5156f21468352dc92d934393f125a2f2d31c469e/assets/images/juejin.png -------------------------------------------------------------------------------- /assets/images/nga.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/TyrantG/hikerViewRules/5156f21468352dc92d934393f125a2f2d31c469e/assets/images/nga.png -------------------------------------------------------------------------------- /assets/images/pica.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/TyrantG/hikerViewRules/5156f21468352dc92d934393f125a2f2d31c469e/assets/images/pica.jpg -------------------------------------------------------------------------------- /assets/images/qie_e.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/TyrantG/hikerViewRules/5156f21468352dc92d934393f125a2f2d31c469e/assets/images/qie_e.png -------------------------------------------------------------------------------- /assets/images/twitch.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/TyrantG/hikerViewRules/5156f21468352dc92d934393f125a2f2d31c469e/assets/images/twitch.png -------------------------------------------------------------------------------- /assets/images/youtube.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/TyrantG/hikerViewRules/5156f21468352dc92d934393f125a2f2d31c469e/assets/images/youtube.png -------------------------------------------------------------------------------- /assets/images/zcool.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/TyrantG/hikerViewRules/5156f21468352dc92d934393f125a2f2d31c469e/assets/images/zcool.jpg -------------------------------------------------------------------------------- /data/music_list.json: -------------------------------------------------------------------------------- 1 | [ 2 | { 3 | "name": "我喜欢的音乐", 4 | "type": "love", 5 | "desc": "我喜欢的音乐", 6 | "cover_image": "https://wp.stanforddaily.com/wp-content/uploads/2021/05/The-Off-Season.png", 7 | "list": [ 8 | { 9 | "id": "1844671640", 10 | "name": "h u n g e r . o n . h i l l s i d e", 11 | "cover_image": "http://p1.music.126.net/vVV6_b_CfNzBfv4rVfiwOw==/109951165975303461.jpg?param=300x300", 12 | "author": "J. Cole,Bas", 13 | "link": "http://music.163.com/#/song?id=1844671640", 14 | "lrc": "[00:00.000] 作词 : J. Cole\n[00:01.000] 作曲 : J. Cole\n[00:11.634](Alright now, alright now)\n[00:19.725](God has a prayer for you)\n[00:29.103](And all you got to do is believe, believe)\n[00:36.057]Yeah\n[00:36.363]\n[00:37.308]S**t gon' get hard keep your head strong\n[00:39.387]If I quit now then I'm dead wrong\n[00:42.023]Fightin' off this hunger for hours\n[00:44.653]Big stepper, n***a, don't get stepped on\n[00:47.038]They money might fade, but respect don't\n[00:49.662]Still gon' be me when success gone\n[00:52.166]I don't speak the language of cowards\n[00:54.627]I walk through the flame like I'm Teflon\n[00:57.157]\n[00:57.320]I sucked up the pain and I kept goin'\n[00:59.635]Whole world know my name, b***h, my rep strong\n[01:02.378]We sold out in lеss than an hour\n[01:04.789]These words I still sang like I'm slеpt on\n[01:07.363]I sin, so I can't cast the next stone\n[01:09.857]Unless it's baguettes 'round my neck bone\n[01:12.428]Inside of my frame lies a power\n[01:14.823]You can't get this game from no TED Talk\n[01:17.379]I wanna know if they understand me\n[01:19.859]I put it all on A, ain't no plan B\n[01:22.560]Hopin' all this weight ain't gon' drown me\n[01:25.010]****ed around, got grey hairs already\n[01:27.564]Runnin' up the stairs on a tower\n[01:30.246]Runnin' up these M's by the hour\n[01:32.746]If I drop a gem, money showers\n[01:35.076]When you get your taste they get sour\n[01:37.644]\n[01:37.831]S**t gon' get hard, keep your head strong (Head strong)\n[01:42.735]The money might fade, but respect don't (The ultimate price is regret now)\n[01:47.944]Still gon' be me when success gone (Still gon' be me)\n[01:52.912]Big stepper, n***a, don't get stepped on (Ah)\n[01:55.563]\n[01:57.201]Waiting my turn like grains of sand inside a hourglass\n[01:59.645]Mainly concerned back in the day with how long I would last\n[02:02.169]Make a few thousand dollars, stack with every hour passed\n[02:04.562]I catch you playin' inside my lane and I'ma foul your ass\n[02:07.161]Put whole game on top of my back, don't need no chiropract\n[02:09.670]They callin' me young PWC I got my power back\n[02:12.119]Ain't ****in' around, beefin' with me gon' get you hollered at\n[02:14.696]N***as can't see me 101, that's word to Kyla Pratt\n[02:17.188]You hitting them weights, congratulations 'cause you built somethin'\n[02:19.769]You takin' a lot of boxin' lessons but you still pussy\n[02:22.296]I still see right through you n***as just like 2Pac hologram\n[02:24.863]Ain't doin' Coachella, bookin' me gon' be a lot of M's\n[02:27.300]I'm feeling myself, I'm building my wealth up 'til it's tirin'\n[02:29.843]I put my tongue all in my b***h, she get to hollerin'\n[02:32.258]I ain't doin' no dirt no more, I stopped creepin' six years ago\n[02:34.951]Fun ****in' them hoes until you realize that you is the hoe\n[02:37.351]\n[02:38.485]S**t gon' get hard keep your head strong\n[02:41.053]If I quit now then I'm dead wrong\n[02:43.216]Fightin' off this hunger for hours\n[02:45.936]Big stepper, n***a, don't get stepped on\n[02:48.327]They money might fade, but respect don't\n[02:50.848]Still gon' be me when success gone\n[02:53.515]I don't speak the language of cowards\n[02:55.935]I walk through the flame like I'm Teflon\n[02:58.255]\n[02:58.633]Can't be afraid of sunlight\n[03:00.937]Spotlights when it close\n[03:03.656]All the pain you hold\n[03:05.563]Makes you worth your weight in gold\n[03:08.760]Can't be afraid of sunlight\n[03:11.230]Spotlights when it close\n[03:13.688]All the pain you hold\n[03:15.759]Makes you worth your weight in gold\n[03:16.991]Ah-ah, ah-ah, ah-ah, ah-ah\n[03:27.022]Ah-ah, ah-ah, ah-ah, ah-ah\n", 15 | "type": "netease", 16 | "url": "http://music.163.com/song/media/outer/url?id=1844671640.mp3" 17 | } 18 | ] 19 | } 20 | ] -------------------------------------------------------------------------------- /public/CloudMusic.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 10 | TyrantGenesis 自制播放器 11 | 12 | 13 | 14 | 15 | -------------------------------------------------------------------------------- /public/CloudMusic/tabs.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | TyrantGenesis 自制组件 7 | 8 | 26 | 27 | 28 |
    29 | 30 | {{item.title}} 31 | 32 |
    33 | 34 | 35 | 61 | 62 | -------------------------------------------------------------------------------- /public/banner.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | TyrantGenesis 7 | 8 | 16 | 17 | 18 |
    19 | 20 | 21 | 22 | 23 | 24 |
    25 | 26 | 27 | 49 | 50 | 51 | -------------------------------------------------------------------------------- /public/category.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | Title 7 | 8 | 9 | 10 | 11 | 12 | 33 | 34 | 35 |
    36 | 41 | 42 | 43 | {{tab.name}} 44 | 45 | 46 |
    47 | 127 | 128 | 129 | -------------------------------------------------------------------------------- /public/css/douyu_danmu.css: -------------------------------------------------------------------------------- 1 | body,html{margin:0;padding:0}body,body #app,html,html #app{width:100%;height:100%}body #app .dammu,html #app .dammu{background-color:#000;width:100%;height:100%} -------------------------------------------------------------------------------- /public/douyu-danmu-tabs.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | TyrantGenesis 自制组件 7 | 8 | 26 | 27 | 28 |
    29 | 30 | {{item.title}} 31 | 32 |
    33 | 34 | 35 | 63 | 64 | -------------------------------------------------------------------------------- /public/douyu-player.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 10 | TyrantGenesis 自制播放器 11 | 12 | 42 | 43 | 44 |
    45 |
    46 |
    47 |
    48 | {{item.user}}:{{item.content}} 49 |
    50 |
    51 |
    52 | 53 | 54 | 55 | 86 | 181 | 182 | -------------------------------------------------------------------------------- /public/douyu-tabs.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | TyrantGenesis 自制组件 7 | 8 | 26 | 27 | 28 |
    29 | 30 | {{item.title}} 31 | 32 |
    33 | 34 | 35 | 63 | 64 | -------------------------------------------------------------------------------- /public/douyu_danmu.html: -------------------------------------------------------------------------------- 1 | douyu_danmu
    -------------------------------------------------------------------------------- /public/fonts/AlexBrush-Regular.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/TyrantG/hikerViewRules/5156f21468352dc92d934393f125a2f2d31c469e/public/fonts/AlexBrush-Regular.ttf -------------------------------------------------------------------------------- /public/gcores_banners.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | Banners 7 | 8 | 38 | 39 | 40 |
    41 | 42 | 43 | 44 | 45 | 46 |
    47 | 48 | 49 | 121 | 122 | -------------------------------------------------------------------------------- /public/huya-category.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 27 | 28 | 29 |
    30 | 31 | 32 | 33 |
    34 | 58 | 59 | 60 | -------------------------------------------------------------------------------- /public/huya-tabs.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | TyrantGenesis 自制组件 7 | 8 | 26 | 27 | 28 |
    29 | 30 | {{item.title}} 31 | 32 |
    33 | 34 | 35 | 61 | 62 | -------------------------------------------------------------------------------- /public/mix-manifest.json: -------------------------------------------------------------------------------- 1 | { 2 | "/js/app.js": "/js/app.js", 3 | "/js/app.js.map": "/js/app.js.map" 4 | } 5 | -------------------------------------------------------------------------------- /public/netEasy-music-master/.gitignore: -------------------------------------------------------------------------------- 1 | /node_modules 2 | -------------------------------------------------------------------------------- /public/netEasy-music-master/README.md: -------------------------------------------------------------------------------- 1 | # 移动端网易云音乐 2 | 3 | ### JavaScript + jQuery + LeanCloud仿移动端网易云音乐 4 | ### 链接二维码 5 | ![](https://i.loli.net/2018/01/18/5a605e4728bb4.png) 6 | 7 | **Notice:** _请使用**手机浏览器扫一扫** 或 **电脑开启device mode**浏览_ 8 | 9 | 10 | ## 页面构成 11 | 12 | ### 1. 首页 13 | + 推荐音乐 14 | + 热歌榜 15 | + 歌曲搜索 16 | 17 | ### 2. 歌单详情页 18 | + 歌单简介 19 | + 歌单歌曲列表 20 | 21 | ### 3. 歌曲播放页 22 | + 歌曲唱片动画 23 | + 歌词滚动高亮 24 | 25 | 26 | - 百分百像素级还原 27 | - flex布局 28 | - 原生js实现 29 | - 模拟数据 30 | 31 | ## 问题 32 | 33 | - **防止margin合并** 34 | ``` 35 | .noCollapse::after{ 36 |  content:''; 37 |  display:table; 38 | } 39 | .noCollapse::before{ 40 |  content:''; 41 |  display:table; 42 | } 43 | ``` 44 | - **背景模糊 变暗** 45 | ``` 46 | filter: blur(100px) brightness(.2); 47 | ``` 48 | - **多行文字的ellipsis效果**实现: 49 | ``` 50 | element { 51 | display: -webkit-box; 52 | -webkit-line-clamp:2; 53 | -webkit-box-orient: vertical; 54 | overflow:hidden; 55 | } 56 | ``` 57 | 58 | 59 | 60 | 遇到问题解决方法: 61 | 1. 网速慢时图片闪烁 62 | 2. 搜索网络请求过多,使用函数节流,减少搜索时请求次数 63 | 3. transform动画是否会覆盖以前的transform 64 | 4. git问题 65 | ``` 66 | $ git pull 67 | 68 | Pull is not possible because you have unmerged files. 69 | Please, fix them up in the work tree, and then use 'git add/rm ' 70 | as appropriate to mark resolution, or use 'git commit -a' 71 | 72 | 应该是因为local文件冲突了 73 | 74 | 解决方法: 75 | 1.pull会使用git merge导致冲突,需要将冲突的文件resolve掉 git add -u, git commit之后才能成功pull. 76 | 2.如果想放弃本地的文件修改,可以使用git reset --hard FETCH_HEAD,FETCH_HEAD表示上一次成功git pull之后形成的commit点。然后git pull. 77 | 注意: 78 | git merge会形成MERGE-HEAD(FETCH-HEAD) 。git push会形成HEAD这样的引用。HEAD代表本地最近成功push后形成的引用。 79 | ``` 80 | 5. 填数据时js里a的链接相对于html写的,没有考虑是填充后的路径 81 | 6. 背景图片写在了伪类,添加动态数据问题, 82 | 7. 歌词lyric 需要回车,去掉\n 83 | 8. ~~ 去掉小数部分,保留整数部分 把小数变成整数 84 | 9. 歌词滚动问题css写好不做动画,解决方法是细节问题 85 | 86 | 87 | 88 | ### 歌曲播放页 89 | 90 | 1. **歌曲播放页disc唱片部分的播放/暂停动画**,主要使用了CSS3的`animation`实现,特别是`animation-play-state`的使用。不过,**这里有一个小bug**,即**在ios上的webkit内核浏览器中(例如:safari,chrome),`-webkit-animation-play-state:paused`不起作用**,也就是说,动画会一直进行下去,即使按了暂停按钮。当然,可以用jQuery的addClass/removeClass方法配合CSS3的`.no-animation{-webkit-animation:none!important;}`样式解决这个bug,但是这又会产生新的问题,即点击暂停,动画此时可以暂停;但是当再次点击播放时,动画就会重新开始,而不是接着之前的状态继续。所以这两种方法都不太完美。这里我选用了第一种方法。 91 | 2. **歌曲播放页disc指针部分的播放/暂停动画**,主要使用了CSS3的`transform`实现,特别是`transform:rotate()`的使用。但是transform属性默认是以`transform-origin:50% 50%`为固定点进行旋转。而这里**需要以disc指针的顶部为固定点进行旋转**,所以应设置其样式为`transform-origin:left top;`。 92 | 93 | ## 性能优化 94 | 95 | ### HTML 96 | 1. **尽量避免了使用多层标签嵌套**,同时选择`::before`和`::after`**伪元素减少html标签的使用**。 97 | 2. 用link标签引入外部css样式表,放入<head>标签内的最底部,用script标签引入外部JavaScript脚本放入<body>标签内的最底部。 98 | 99 | ### CSS 100 | 1. **选择器层级嵌套匹配尽量不要超过4层**。 101 | 2. **需要经常复用的样式尽量写在一个className上**,然后在html中相应的元素上添加className。 102 | 3. **尽量使用简写/复合样式**,比如,`background,animation`等简写属性。 103 | 104 | ### JavaScript 105 | 1. 使用了立即执行函数(IIFE)把代码封闭。 106 | 2. 主要代码使用了构造函数和原型对象进行了封装。 107 | 3. 将固定不变的节点保存到变量,减少重复调用。 108 | 109 | ### Gulp 110 | 111 | 1. 对图片压缩(使用了[gulp-imagemin](https://www.npmjs.com/package/gulp-imagemin))。 112 | 2. 给CSS自动补全前缀并压缩(使用了[gulp-autoprefixer](https://www.npmjs.com/package/gulp-autoprefixer),[gulp-cssnano]())。 113 | 3. 对HTML压缩(使用了[gulp-htmlmin](https://www.npmjs.com/package/gulp-htmlmin))。 114 | 115 | ### Webpack 116 | 117 | 1. 使用了`UglifyJsPlugin()`方法对JavaScript文件压缩。 118 | -------------------------------------------------------------------------------- /public/netEasy-music-master/css/reset.css: -------------------------------------------------------------------------------- 1 | *{ 2 | margin: 0; 3 | padding: 0; 4 | } 5 | *{ 6 | box-sizing: border-box; 7 | } 8 | *::after{ 9 | box-sizing: border-box; 10 | } 11 | *::before{ 12 | box-sizing: border-box; 13 | } 14 | 15 | a{ 16 | color: inherit; 17 | text-decoration: none; 18 | } 19 | ul,ol,li{ 20 | list-style: none; 21 | } 22 | h1,h2,h3,h4,h5,h6{ 23 | font-weight: normal; 24 | } 25 | body{ 26 | font: 14px/1.5 Helvetica,sans-serif; 27 | } 28 | 29 | /*icon*/ 30 | 31 | .icon { 32 | width: 1em; height: 1em; 33 | vertical-align: -0.15em; 34 | fill: currentColor; 35 | overflow: hidden; 36 | } -------------------------------------------------------------------------------- /public/netEasy-music-master/css/song.css: -------------------------------------------------------------------------------- 1 | @keyframes circle{ 2 | 0%{ 3 | transform: rotate(0deg); 4 | } 5 | 100%{ 6 | transform: rotate(360deg); 7 | } 8 | } 9 | 10 | .page{ 11 | display: flex; 12 | flex-direction: column; 13 | height: 100vh; 14 | position: relative; 15 | } 16 | .page::before{ 17 | content: ''; 18 | position: absolute; 19 | top: 0px; 20 | left: 0px; 21 | width: 100%; 22 | height: 100vh; 23 | z-index: -1; 24 | /*background:transparent url(//i.loli.net/2017/10/08/59da11c6739ab.jpg)no-repeat center; 25 | background-size: cover;*/ 26 | filter: blur(10px) brightness(.4); 27 | } 28 | .page::after{ 29 | content: ""; 30 | display: block; 31 | position: absolute; 32 | top: 0; 33 | left: 0; 34 | right: 0; 35 | bottom: 0; 36 | z-index: -1; 37 | background-color: hsla(0,100%,0%,0.5); 38 | } 39 | 40 | section.pointer{ 41 | position: relative; 42 | 43 | } 44 | section.pointer .logo{ 45 | position: absolute; 46 | top: 12px; 47 | left: 10px; 48 | display: block; 49 | width: 100px; 50 | height: 17px; 51 | } 52 | section.pointer .point{ 53 | width: 84px; 54 | height: 122px; 55 | position: absolute; 56 | left: 45%; 57 | z-index: 2; 58 | transform-origin: 10% 0%; 59 | transition: 1s; 60 | } 61 | section.pointer .point.rotate{ 62 | transform: rotate(-15deg); 63 | transform-origin: 10% 0%; 64 | transition: transform 1s; 65 | } 66 | 67 | section.disk{ 68 | position: relative; 69 | margin-top: 63px; 70 | } 71 | section.disk .circle{ 72 | width: 248px; 73 | height: 248px; 74 | margin: 0 auto; 75 | position: relative; 76 | /*display: flex; 77 | justify-content: center; 78 | align-items: center;*/ 79 | } 80 | .icon-wrapper{ 81 | position:absolute; 82 | top: 50%; 83 | left: 50%; 84 | transform: translate(-50%,-50%); 85 | z-index: 2; 86 | display: flex; 87 | justify-content: center; 88 | align-items: center; 89 | border: 1px solid #fff; 90 | border-radius: 50%; 91 | padding: 7px; 92 | } 93 | .icon-wrapper .iconfont{ 94 | width: 25px; 95 | height: 25px; 96 | vertical-align: -0.15em; 97 | overflow: hidden; 98 | fill: #fff; 99 | } 100 | section.disk .icon-pause{ display: none; } 101 | section.disk.playing .icon-bofang{display: none;} 102 | section.disk.playing .icon-pause{display: block;} 103 | 104 | 105 | 106 | section.disk .circle::before{ 107 | content: ''; 108 | position: absolute; 109 | top: 0; 110 | left: 0; 111 | width: 100%; 112 | height: 100%; 113 | background: transparent url(https://i.loli.net/2018/01/18/5a6068986f993.png) no-repeat center; 114 | background-size: cover; 115 | } 116 | section.disk .circle::after{ 117 | content: ''; 118 | position: absolute; 119 | top: 0; 120 | left: 0; 121 | width: 100%; 122 | height: 100%; 123 | background: transparent url(https://i.loli.net/2018/01/18/5a606898095c6.png) no-repeat center; 124 | background-size: cover; 125 | } 126 | section.disk .circle > img{ 127 | width: 150px; 128 | height: 150px; 129 | position: absolute; 130 | top: 50%; 131 | left: 50%; 132 | margin-top: -75px; 133 | margin-left: -75px; 134 | border-radius: 50%; 135 | display: block; 136 | } 137 | section.disk.playing .circle::after, 138 | section.disk.playing .circle > img{ 139 | animation: circle 20s infinite linear; 140 | } 141 | 142 | /*随时随地停止*/ 143 | section.disk.pause .circle::after, 144 | section.disk.pause .circle > img{ 145 | animation: circle 20s infinite linear; 146 | animation-play-state: paused; 147 | } 148 | 149 | /*歌词*/ 150 | section.lyric{ 151 | /*占据中间*/ 152 | flex-grow: 1; 153 | margin-top: 20px; 154 | padding: 0 35px; 155 | line-height: 2; 156 | text-align: center; 157 | color: #fefefe; 158 | } 159 | section.lyric h1{ 160 | font-size: 15px; 161 | overflow: hidden; 162 | white-space: nowrap; 163 | text-overflow: ellipsis 164 | } 165 | section.lyric .word{ 166 | margin-top: 7px; 167 | height: 72px; 168 | overflow: hidden; 169 | } 170 | section.lyric .word p{ 171 | font-size: 13px; 172 | line-height: 24px; 173 | color: hsla(0,0%,100%,.6); 174 | } 175 | section.lyric .word .lines{ 176 | transition: transform .3s; 177 | } 178 | section.lyric .lines p.active{ 179 | color: #fefefe; 180 | font-size: 15px; 181 | } 182 | 183 | 184 | /*链接*/ 185 | section.links{ 186 | display: flex; 187 | justify-content: center; 188 | align-items: center; 189 | } 190 | 191 | section.links a{ 192 | /*display: inline-block;*/ 193 | width: 145px; 194 | height: 40px; 195 | line-height: 40px; 196 | padding: 0 6px; 197 | margin: 10px; 198 | border: 1px solid #d33a31; 199 | border-radius: 40px; 200 | font-size: 18px; 201 | color: #d33a31; 202 | text-align: center; 203 | background: transparent; 204 | letter-spacing: 5px; 205 | } 206 | section.links a.main{ 207 | background: #d33a31; 208 | color: #fff; 209 | } 210 | 211 | .boomText{ 212 | opacity: 0; 213 | display: inline-block; 214 | } 215 | -------------------------------------------------------------------------------- /public/netEasy-music-master/js/av.js: -------------------------------------------------------------------------------- 1 | //初始化 2 | var APP_ID = 'eNuy1gIwgY9cI6KeKsGfw3Mr-gzGzoHsz'; 3 | var APP_KEY = 'DX4tkQ07mmA8cQHGujuTa6aT'; 4 | 5 | AV.init({ 6 | appId: APP_ID, 7 | appKey: APP_KEY 8 | }); 9 | 10 | 11 | // 最新音乐加载 12 | // var SongObject = AV.Object.extend('Song'); // 选择表名 13 | // var songOBject = new SongObject(); // 生成一条数据 14 | // songOBject.save({ 15 | // name: '等你下课', 16 | // singer: '周杰伦', 17 | // cover: '//i.loli.net/2018/01/19/5a61a88f9b1bc.jpg', 18 | // url: 'http://owyvuq3lo.bkt.clouddn.com/C400001J5QJL1pRQYB.m4a' 19 | // }).then(function(object) { 20 | // alert('LeanCloud Rocks!'); 21 | // }) -------------------------------------------------------------------------------- /public/netEasy-music-master/js/device.js: -------------------------------------------------------------------------------- 1 | let width = document.documentElement.clientWidth 2 | console.log(width) 3 | let css = ` 4 | html{ 5 | font-size: ${width / 10}px; 6 | } 7 | ` 8 | let style = `` 9 | 10 | document.write(style) -------------------------------------------------------------------------------- /public/netEasy-music-master/js/playlist.js: -------------------------------------------------------------------------------- 1 | // 获取url 的id 2 | function getParameterByName(name, url) { 3 | if (!url) url = window.location.href; 4 | name = name.replace(/[\[\]]/g, "\\$&"); 5 | var regex = new RegExp("[?&]" + name + "(=([^&#]*)|&|#|$)"), 6 | results = regex.exec(url); 7 | if (!results) return null; 8 | if (!results[2]) return ''; 9 | return decodeURIComponent(results[2].replace(/\+/g, " ")); 10 | } 11 | 12 | let $cover = $('.cover') 13 | let $info = $('.playlist-head .info') 14 | 15 | let id = getParameterByName('id'); 16 | var query = new AV.Query('Playlist'); 17 | query.get(id).then(function(list){ 18 | console.log(list) 19 | let wrapImg = list.attributes 20 | let wrap = `` 21 | let word = `

    ${wrapImg.title}

    ` 22 | $info.prepend(word) 23 | $cover.append(wrap) 24 | }) 25 | 26 | 27 | 28 | 29 | 30 | let $intro = $('#intro') 31 | $intro.on('click', function () { 32 | let $upButton = $('.playlist-info .arrow .icon-arrow-up') 33 | let $downButton = $('.playlist-info .arrow .icon-arrow-down') 34 | if ($intro.hasClass('active')) { 35 | $intro.removeClass('active') 36 | $upButton.css('display', 'inline') 37 | $downButton.css('display', 'none') 38 | } else { 39 | $intro.addClass('active') 40 | $upButton.css('display', 'none') 41 | $downButton.css('display', 'inline') 42 | } 43 | }) 44 | 45 | 46 | 47 | let $list = $('.playlist-content .list') 48 | var query = new AV.Query('Song') 49 | query.limit(20) 50 | query.find().then(function (results) { 51 | for (let i = 0; i < results.length; i++) { 52 | let song = results[i].attributes 53 | let songId = results[i].id 54 | let li = `
  • 55 | 56 |
    ${i+1}
    57 |
    58 |
    59 |

    ${song.name}

    60 |

    ${song.singer}

    61 |
    62 |
    63 | 64 | 65 | 66 |
    67 |
    68 |
    69 |
  • ` 70 | $list.append(li) 71 | if (song.transName) { 72 | console.log(song.transName) 73 | let span = `(${song.transName})` 74 | $list.find($('.list-text h3')).eq(i).append(span) 75 | } 76 | } 77 | }, function (error) { 78 | alert(error) 79 | }) -------------------------------------------------------------------------------- /public/netEasy-music-master/js/song.js: -------------------------------------------------------------------------------- 1 | // 获取url 的id 2 | function getParameterByName(name, url) { 3 | if (!url) url = window.location.href; 4 | name = name.replace(/[\[\]]/g, "\\$&"); 5 | var regex = new RegExp("[?&]" + name + "(=([^&#]*)|&|#|$)"), 6 | results = regex.exec(url); 7 | if (!results) return null; 8 | if (!results[2]) return ''; 9 | return decodeURIComponent(results[2].replace(/\+/g, " ")); 10 | } 11 | 12 | 13 | let id = getParameterByName('id'); 14 | var query = new AV.Query('Song'); 15 | query.get(id).then(function(song){ 16 | // 解构获取歌曲url 17 | let {url,lyric,cover,name,singer} = song.attributes 18 | 19 | 20 | imagesInit.call(undefined,cover) 21 | initPlayer.call(undefined,url) 22 | initText(name,lyric) 23 | }) 24 | 25 | // 歌词数据 26 | function initText(name,lyric){ 27 | $('.lyric > h1').text(name) 28 | parseLyric(lyric) 29 | } 30 | 31 | function imagesInit(cover) { 32 | // 添加css伪类 33 | var s=""; 34 | $('head').append(s) 35 | document.querySelector('#bg').src = cover; 36 | } 37 | 38 | //歌词 39 | function parseLyric(lyric){ 40 | //解构 41 | let array = lyric.split('\n') 42 | 43 | // 正则匹配分开时间[ ]和歌词 44 | // let regex = /^\[(.+)\](.*)$/ 45 | let regex = /^\[(.+)\](.+)/ 46 | //遍历数组,得到时间和歌词 47 | array = array.map(function(string,index){ 48 | let matches = string.match(regex) 49 | if (matches) { 50 | return {time:matches[1],words:matches[2]} 51 | } 52 | }) 53 | let $lyric = $('.word') 54 | array.map(function(object){ 55 | // 创建p标签 56 | if (!object) {return} 57 | let $p = $('

    ') 58 | //给每一个标签自定义时间属性,然后的文本内容是words 59 | $p.attr('data-time',object.time).text(object.words) 60 | //插入div 61 | $p.appendTo($lyric.children('.lines')) 62 | }) 63 | } 64 | 65 | // 初始化暂停播放 66 | function initPlayer(url){ 67 | let audio = document.createElement("audio") 68 | audio.src = url; 69 | audio.oncanplay = function(){ 70 | audio.play() 71 | $('section.disk').addClass('playing') 72 | $('section.disk').removeClass('pause') 73 | } 74 | $(".icon-pause").on('click',function(){ 75 | audio.pause() 76 | $('section.disk').removeClass('playing') 77 | $('section.disk').addClass('pause') 78 | $('section.pointer .point').addClass('rotate') 79 | }) 80 | $(".icon-bofang").on('click',function(){ 81 | audio.play() 82 | $('section.disk').addClass('playing') 83 | $('section.disk').removeClass('pause') 84 | $('section.pointer .point').removeClass('rotate') 85 | }) 86 | //歌词动画 87 | setInterval(function(){ 88 | let seconds = audio.currentTime 89 | let munites = ~~ (seconds / 60) 90 | let left = seconds - munites *60 91 | let time = `${pad(munites)}:${pad(left)}`; // 问题: 不能分开 92 | 93 | let $lines = $('.lines>p') 94 | 95 | let $whichline 96 | for (let i = 0; i < $lines.length; i++) { 97 | // 歌曲时间 98 | let currentLine = $lines.eq(i).attr('data-time') 99 | let nextLine = $lines.eq(i + 1).attr('data-time') 100 | 101 | 102 | 103 | if ($lines.eq(i+1).length !== 0 && currentLine < time && nextLine > time) { 104 | $whichline = $lines.eq(i) 105 | break 106 | } 107 | } 108 | if ($whichline) { 109 | //高亮 110 | $whichline.addClass('active').prev().removeClass('active') 111 | //高度计算往上移动距离 112 | let top = $whichline.offset().top 113 | let linesTop = $('.lines').offset().top 114 | let delta = top - linesTop - $('.word').height()/3 115 | 116 | $('.lines').css('transform', `translateY(-${delta}px)`) 117 | 118 | } 119 | },300) 120 | } 121 | 122 | function pad(num){ 123 | return num >= 10 ? num + '' : '0' + num 124 | } 125 | -------------------------------------------------------------------------------- /public/netEasy-music-master/js/tab.js: -------------------------------------------------------------------------------- 1 | $('.tabs').on('click','li',function(e){ 2 | //监听的元素 3 | let $li = $(e.currentTarget) 4 | let index = $li.index() 5 | $li.addClass('active').siblings().removeClass('active') 6 | 7 | $('.tab-content').children().eq(index) 8 | .addClass('active').siblings().removeClass('active') 9 | }) -------------------------------------------------------------------------------- /public/netEasy-music-master/package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "netEasy-Music", 3 | "version": "1.0.0", 4 | "description": "", 5 | "main": "index.js", 6 | "scripts": { 7 | "test": "echo \"Error: no test specified\" && exit 1" 8 | }, 9 | "keywords": [], 10 | "author": "", 11 | "license": "ISC", 12 | "dependencies": { 13 | "gulp": "^3.9.1", 14 | "jquery": "^3.2.1", 15 | "leancloud-storage": "^3.5.0", 16 | "loaders.css": "^0.1.2" 17 | } 18 | } 19 | -------------------------------------------------------------------------------- /public/netEasy-music-master/playlist.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 |
    15 | 16 |
    17 |
    18 |
    19 | 20 | 歌单 21 |
    22 | 23 | 24 | 25 | 59.3万 26 |
    27 |
    28 |
    29 | 30 |
    31 |
    32 | 33 | 34 |
    35 |

    YYM雨蒙

    36 |
    37 |
    38 |
    39 | 40 |
    41 |
    42 | 标签: 43 |
    44 | 韩语 45 | 清新 46 | 放松 47 |
    48 |
    49 |
    50 | 简介:甜而不腻的曲调,淡而不俗的嗓音
    51 |
    52 | 按下播放键
    53 |
    54 | 享受这扑面而来的小清新
    55 |
    56 | 57 |
    58 |
    59 | 创单时间:2017.8.19
    60 |
    61 | 封面:郑恩地 62 |
    63 |
    64 | 65 | 66 | 67 | 68 | 69 | 70 |
    71 |
    72 | 73 |
    74 |
      75 |

      歌曲列表

      76 | 77 |
    78 |
    79 | 82 |
    83 | 84 | 85 | 86 | 87 | 88 | 89 | 90 | 91 | 92 | 93 | 94 | 95 | 96 | -------------------------------------------------------------------------------- /public/netEasy-music-master/song.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 歌曲播放 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 |
    14 | 15 | 16 |
    17 | 18 | 指针 19 |
    20 | 21 |
    22 |
    23 | 24 | 25 | 26 | 27 | 28 | 29 |
    30 |
    31 | 封面 32 | 33 |
    34 |
    35 | 36 | 37 |
    38 |

    39 |
    40 | 41 |
    42 |

    成龙:该愤怒

    43 |

    成龙:该愤怒

    44 |

    成龙:该愤怒

    45 |

    成龙:该愤怒

    46 |

    成龙:该愤怒

    47 |

    成龙:该愤怒

    48 |

    成龙:该愤怒

    49 |

    成龙:该愤怒

    50 |

    成龙:该愤怒

    51 |

    成龙:该愤怒

    52 |

    成龙:该愤怒

    53 |

    成龙:该愤怒

    54 |

    成龙:该愤怒

    55 |

    成龙:该愤怒

    56 |

    成龙:该愤怒

    57 |

    成龙:该愤怒

    58 |

    成龙:该愤怒

    59 |

    成龙:该愤怒

    60 |

    成龙:该愤怒

    61 |
    62 |
    63 | 64 |
    65 | 66 | 70 | 71 |
    72 | 73 | 74 | 75 | 76 | 77 | 78 | 79 | -------------------------------------------------------------------------------- /public/new_home.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 新主页 6 | 7 | 8 | 9 | 10 | -------------------------------------------------------------------------------- /public/qieEgame-tabs.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | TyrantGenesis 自制组件 7 | 8 | 26 | 27 | 28 |
    29 | 30 | {{item.title}} 31 | 32 |
    33 | 34 | 35 | 61 | 62 | -------------------------------------------------------------------------------- /tyrantgenesis.js: -------------------------------------------------------------------------------- 1 | const BASE_URL = "https://git.tyrantg.com/tyrantgenesis/hikerViewRules/raw/master/" 2 | const collection_password = "海阔视界,首页频道合集¥home_rule_url¥" 3 | const rule_password = "海阔视界规则分享,当前分享的是:小程序¥home_rule_v2¥" 4 | 5 | const baseParse = _ => { 6 | let res = {}; 7 | let d = []; 8 | const script = fetch(MY_URL); 9 | const data_json = fetch('hiker://files/TyrantG/data/base.json'); 10 | 11 | const data = JSON.parse(data_json) 12 | 13 | let fst_rule_list = [] 14 | let snd_rule_list = [] 15 | 16 | eval(script); 17 | 18 | d.push({ 19 | title: '跑路了,崩撤卖溜', 20 | url: 'https://git.tyrantg.com/tyrantgenesis/hikerViewRules', 21 | col_type: 'text_1' 22 | }) 23 | d.push({ 24 | pic_url: 'http://test-homepage.dev.tyrantg.com/img/llll.gif', 25 | url: 'http://test-homepage.dev.tyrantg.com/img/llll.gif', 26 | col_type: 'pic_1_full' 27 | }) 28 | 29 | data.forEach(rule => { 30 | fst_rule_list = [] 31 | rule.data.forEach(item => { 32 | item.rules.forEach(each => { 33 | fst_rule_list.push(each.rule) 34 | }) 35 | }) 36 | writeFile("hiker://files/TyrantG/Temporary/"+rule.title+".json", JSON.stringify(fst_rule_list)); 37 | 38 | d.push({ 39 | title: rule.title, 40 | url: "rule://"+base64Encode(collection_password+"hiker://files/TyrantG/Temporary/"+rule.title+".json").replace(/\n/g, ''), 41 | col_type: 'text_center_1' 42 | }); 43 | 44 | rule.data.forEach(item => { 45 | snd_rule_list = [] 46 | item.rules.forEach(each => { 47 | snd_rule_list.push(each.rule) 48 | }) 49 | writeFile("hiker://files/TyrantG/Temporary/"+rule.title+"/"+item.title+".json", JSON.stringify(snd_rule_list)); 50 | d.push({ 51 | title: item.title, 52 | url: "rule://"+base64Encode(collection_password+"hiker://files/TyrantG/Temporary/"+rule.title+"/"+item.title+".json").replace(/\n/g, ''), 53 | col_type: 'text_2' 54 | }); 55 | item.rules.forEach(each => { 56 | d.push({ 57 | title: each.title, 58 | url: "rule://"+base64Encode(rule_password+JSON.stringify(each.rule)).replace(/\n/g, ''), 59 | col_type: 'flex_button' 60 | }) 61 | }) 62 | d.push({ 63 | col_type: 'line' 64 | }); 65 | }) 66 | 67 | d.push({ 68 | col_type: 'line_blank' 69 | }); 70 | }) 71 | 72 | res.data = d; 73 | setHomeResult(res); 74 | } 75 | 76 | const homePage = _ => { 77 | let hikerRules = getLastRules(12), rules = [] 78 | hikerRules.forEach(item => { 79 | rules.push(item.title) 80 | }) 81 | putVar('tyrantgenesis.rules', JSON.stringify(rules)) 82 | 83 | let d = []; 84 | 85 | d.push({ 86 | desc: '100% && float', 87 | url: 'file:///storage/emulated/0/Android/data/com.example.hikerview/files/Documents/TyrantG/public/Home.html?time='+(new Date()).getTime(), 88 | col_type:"x5_webview_single" 89 | }) 90 | 91 | setResult(d); 92 | } --------------------------------------------------------------------------------