移除cat.js
This commit is contained in:
@@ -4,7 +4,7 @@
|
||||
2. uzCode.js 内部定义了一些类和方法,您需要在脚本中实现 WebApiBase 的所有方法
|
||||
3. uz 内部仅有一个运行时,所有 js 代码(包括脚本)都在一起加载执行。所以您的脚本内类名一定要特殊,实例名称也要特殊
|
||||
4. 不支持 import export
|
||||
5. 集成了 cat.js.由于不支持 export, 对 cat.js 做了简单修改
|
||||
5. 集成库可在 `uz3lib.js` 查看,如需添加其他库通用库请联系[机器人](https://t.me/uzVideoAppbot)
|
||||
6. 成对使用 `// ignore` uz 内部会忽略包裹的内容
|
||||
7. 为您的脚本编写以下 json 配置文件
|
||||
|
||||
|
||||
4
js/core/CryptoJS.min.js
vendored
Normal file
4
js/core/CryptoJS.min.js
vendored
Normal file
File diff suppressed because one or more lines are too long
6
js/core/JSEncrypt.min.js
vendored
Normal file
6
js/core/JSEncrypt.min.js
vendored
Normal file
File diff suppressed because one or more lines are too long
27456
js/core/cat.js
27456
js/core/cat.js
File diff suppressed because one or more lines are too long
16
js/core/cheerio.js
Normal file
16
js/core/cheerio.js
Normal file
File diff suppressed because one or more lines are too long
4
js/core/node-html-parser.js
Normal file
4
js/core/node-html-parser.js
Normal file
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
56
js/core/uzUtils.js
Normal file
56
js/core/uzUtils.js
Normal file
@@ -0,0 +1,56 @@
|
||||
class UZUtils {
|
||||
/**
|
||||
* 从链接中获取域名
|
||||
* @param {string} url
|
||||
* @returns
|
||||
*/
|
||||
static getHostFromURL(url) {
|
||||
const protocolEndIndex = url.indexOf("://");
|
||||
if (protocolEndIndex === -1) {
|
||||
return null;
|
||||
}
|
||||
const hostStartIndex = protocolEndIndex + 3;
|
||||
const hostEndIndex = url.indexOf("/", hostStartIndex);
|
||||
const host =
|
||||
hostEndIndex === -1
|
||||
? url.slice(hostStartIndex)
|
||||
: url.slice(hostStartIndex, hostEndIndex);
|
||||
|
||||
return `${url.slice(0, protocolEndIndex + 3)}${host}`;
|
||||
}
|
||||
|
||||
/**
|
||||
* 去除尾部的斜杠
|
||||
* @param {string} str
|
||||
* @returns
|
||||
*/
|
||||
static removeTrailingSlash(str) {
|
||||
if (str.endsWith("/")) {
|
||||
return str.slice(0, -1);
|
||||
}
|
||||
return str;
|
||||
}
|
||||
|
||||
/**
|
||||
* 根据正则表达式获取字符串
|
||||
* @param {*} pattern
|
||||
* @param {string} str
|
||||
* @returns {string}
|
||||
*/
|
||||
static getStrByRegexDefault(pattern, str) {
|
||||
let matcher = pattern.exec(str);
|
||||
if (matcher !== null) {
|
||||
if (matcher.length >= 1) {
|
||||
if (matcher.length >= 1) return matcher[1];
|
||||
}
|
||||
}
|
||||
return str;
|
||||
}
|
||||
|
||||
/**
|
||||
* 用于在 uz 脚本调试模式中展示 log 信息
|
||||
*/
|
||||
static debugLog() {
|
||||
sendMessage("debugLog", JSON.stringify([...arguments]));
|
||||
}
|
||||
}
|
||||
@@ -56,7 +56,7 @@ class ChangZhang20240614 extends WebApiBase {
|
||||
*/
|
||||
async getVideoList(args) {
|
||||
var listUrl = UZUtils.removeTrailingSlash(args.url) + "/page/" + args.page;
|
||||
var backData = new RepVideoClassList();
|
||||
var backData = new RepVideoList();
|
||||
try {
|
||||
let pro = await req(listUrl, null);
|
||||
backData.error = pro.error;
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"version":"1.2.7",
|
||||
"apk":"https://mirror.ghproxy.com/https://github.com/YYDS678/uzVideo/raw/main/uz影视_追剧直播无广免费1.2.7.apk",
|
||||
"ipa":"https://mirror.ghproxy.com/https://github.com/YYDS678/uzVideo/raw/main/uz影视_追剧直播无广免费1.2.7.ipa",
|
||||
"update":"# 本次更新\n- 新增导出日志功能\n- 新增脚本调试功能\n- 新增启动检查更新功能\n- 修复部分已知问题\n\n# 其他\n- 欢迎反馈问题和意见\n- 频道 t.me/uzvideoplay\n- 群组 t.me/uzVideoApp\n- 传话机 t.me/uzVideoAppbot"
|
||||
"version":"1.2.9",
|
||||
"apk":"https://t.me/uzvideoplay/76",
|
||||
"ipa":"https://t.me/uzvideoplay/76",
|
||||
"update":"# 本次更新n- 修复部分已知问题"
|
||||
}
|
||||
|
||||
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Reference in New Issue
Block a user