yz-yuki-plugin 2.0.5-2 → 2.0.5-4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.puppeteerrc.cjs +1 -1
- package/README.md +15 -21
- package/defaultConfig/help/help.yaml +2 -2
- package/lib/apps/bilibili.js +1 -1
- package/lib/apps/help.js +1 -1
- package/lib/apps/version.js +1 -1
- package/lib/apps/weibo.js +1 -1
- package/lib/components/dynamic/Footer.js +1 -1
- package/lib/components/help/Help.js +1 -1
- package/lib/components/version/Version.js +1 -1
- package/lib/index.js +1 -1
- package/lib/main.js +11 -0
- package/lib/models/bilibili/bilibili.buid.fp.js +77 -0
- package/lib/models/bilibili/bilibili.models.js +12 -2
- package/lib/models/bilibili/bilibili.query.js +1 -1
- package/lib/models/bilibili/bilibili.task.js +1 -1
- package/lib/models/weibo/weibo.get.web.data.js +1 -1
- package/lib/models/weibo/weibo.query.js +1 -1
- package/lib/models/weibo/weibo.task.js +1 -1
- package/lib/utils/config.js +3 -3
- package/lib/utils/image.js +4 -4
- package/package.json +20 -35
- package/lib/apps/bilibili.d.ts +0 -6
- package/lib/apps/help.d.ts +0 -6
- package/lib/apps/index.d.ts +0 -4
- package/lib/apps/version.d.ts +0 -6
- package/lib/apps/weibo.d.ts +0 -6
- package/lib/components/dynamic/Account.d.ts +0 -13
- package/lib/components/dynamic/Content.d.ts +0 -12
- package/lib/components/dynamic/Footer.d.ts +0 -11
- package/lib/components/dynamic/ForwardContent.d.ts +0 -6
- package/lib/components/dynamic/LogoText.d.ts +0 -9
- package/lib/components/dynamic/MainPage.d.ts +0 -34
- package/lib/components/help/Help.d.ts +0 -12
- package/lib/components/index.d.ts +0 -5
- package/lib/components/loginQrcode/Page.d.ts +0 -7
- package/lib/components/version/Version.d.ts +0 -8
- package/lib/index.d.ts +0 -5
- package/lib/main.d.ts +0 -1
- package/lib/models/bilibili/bilibili.api.d.ts +0 -70
- package/lib/models/bilibili/bilibili.buid.fp.d.ts +0 -2
- package/lib/models/bilibili/bilibili.get.web.data.d.ts +0 -9
- package/lib/models/bilibili/bilibili.models.d.ts +0 -63
- package/lib/models/bilibili/bilibili.query.d.ts +0 -49
- package/lib/models/bilibili/bilibili.task.d.ts +0 -77
- package/lib/models/bilibili/bilibili.ticket.d.ts +0 -12
- package/lib/models/bilibili/bilibili.wbi.d.ts +0 -11
- package/lib/models/help/help.d.ts +0 -8
- package/lib/models/version/version.d.ts +0 -17
- package/lib/models/weibo/weibo.api.d.ts +0 -18
- package/lib/models/weibo/weibo.get.web.data.d.ts +0 -11
- package/lib/models/weibo/weibo.query.d.ts +0 -38
- package/lib/models/weibo/weibo.task.d.ts +0 -84
- package/lib/utils/config.d.ts +0 -73
- package/lib/utils/image.d.ts +0 -15
- package/lib/utils/paths.d.ts +0 -22
- package/lib/utils/puppeteer.render.d.ts +0 -40
- package/public/output.css +0 -1
- package/resources/img/readme/mini-help.jpg +0 -0
package/.puppeteerrc.cjs
CHANGED
package/README.md
CHANGED
|
@@ -11,12 +11,12 @@
|
|
|
11
11
|
# 🌰一、安装插件
|
|
12
12
|
|
|
13
13
|
## 选择安装方式
|
|
14
|
-
按照网络情况以及使用的bot框架是`
|
|
14
|
+
按照网络情况以及使用的bot框架是`Yunzaijs`还是`Yunzai-V3`,选择对应的安装方式。
|
|
15
15
|
|
|
16
|
-
### ***(一)
|
|
16
|
+
### ***(一)YunzaiJS***
|
|
17
17
|
> 选择其中一种方式安装插件:
|
|
18
18
|
|
|
19
|
-
1. npm包安装到`
|
|
19
|
+
1. npm包安装到`yunzaijs/node_modules`的方式,仅YunzaiJS支持:
|
|
20
20
|
```
|
|
21
21
|
yarn add yz-yuki-plugin -W
|
|
22
22
|
```
|
|
@@ -25,26 +25,26 @@
|
|
|
25
25
|
|
|
26
26
|
* 方式1(推荐):
|
|
27
27
|
|
|
28
|
-
手动新建 `
|
|
28
|
+
手动新建 `yunzaijs/yunzai.config.json` 文件,输入如下内容,`applications`字段添加的 `"yz-yuki-plugin"`即为启用本插件:
|
|
29
29
|
|
|
30
30
|
```json
|
|
31
31
|
{
|
|
32
|
-
"applications": ["
|
|
33
|
-
"middlewares": ["
|
|
32
|
+
"applications": ["@yunzaijs/system", "yz-yuki-plugin"],
|
|
33
|
+
"middlewares": ["@yunzaijs/mys/message", "@yunzaijs/mys/runtime"]
|
|
34
34
|
}
|
|
35
35
|
```
|
|
36
36
|
* 方式2:
|
|
37
37
|
|
|
38
|
-
修改 `
|
|
38
|
+
修改 `yunzaijs/yunzai.config.js`:
|
|
39
39
|
```js
|
|
40
|
-
import { defineConfig } from '
|
|
40
|
+
import { defineConfig } from 'yunzaijs'
|
|
41
41
|
export default defineConfig({
|
|
42
|
-
applications: [
|
|
43
|
-
middlewares: [
|
|
42
|
+
applications: ["@yunzaijs/system", "yz-yuki-plugin"], //该行添加 'yz-yuki-plugin'
|
|
43
|
+
middlewares: ["@yunzaijs/mys/message", "@yunzaijs/mys/runtime"]
|
|
44
44
|
})
|
|
45
45
|
```
|
|
46
46
|
|
|
47
|
-
2. 安装到 `
|
|
47
|
+
2. 安装到 `yunzaijs/plugins` 的方式:
|
|
48
48
|
|
|
49
49
|
> 仅支持Yunzai-Next的分支,选择仓库:
|
|
50
50
|
|
|
@@ -179,14 +179,8 @@ https://m.weibo.cn/u/7643376782 # 7643376782 为崩坏星穹铁道博主uid
|
|
|
179
179
|
||||
|
|
180
180
|
| **其他指令** | | |
|
|
181
181
|
| 查看版本信息 | 查看版本信息 | `#优纪版本` |
|
|
182
|
-
| 更新yuki插件 | 系统指令更新yuki插件,
|
|
183
|
-
| 强制更新yuki插件 | 强制更新yuki插件,
|
|
184
|
-
|
|
185
|
-
</details>
|
|
186
|
-
|
|
187
|
-
<details><summary>样式预览,点击展开</summary>
|
|
188
|
-
|
|
189
|
-

|
|
182
|
+
| 更新yuki插件 | 系统指令更新yuki插件,yunzaiJS需安装`@yunzaijs/system` | `#更新yuki-plugin` |
|
|
183
|
+
| 强制更新yuki插件 | 强制更新yuki插件,yunzaiJS需安装`@yunzaijs/system`| `#强制更新yuki-plugin` |
|
|
190
184
|
|
|
191
185
|
</details>
|
|
192
186
|
|
|
@@ -229,8 +223,8 @@ yarn install
|
|
|
229
223
|
| Nickname | Contribution |
|
|
230
224
|
| :-----------------------------------------------------------------: | ----------------------- |
|
|
231
225
|
|Yunzai-Next||
|
|
232
|
-
| [
|
|
233
|
-
| [
|
|
226
|
+
| [YunzaiJS文档](https://yunzaijs.github.io/docs/) | YunzaiJS 文档 |
|
|
227
|
+
| [YunzaiJS 仓库](https://github.com/yunzaijs/core) | YunzaiJS |
|
|
234
228
|
|Yunzai-V3||
|
|
235
229
|
| [功能/插件库](https://gitee.com/yhArcadia/Yunzai-Bot-plugins-index) | Yunzai-Bot 相关内容索引 |
|
|
236
230
|
| [TRSS-Yunzai](https://gitee.com/TimeRainStarSky/Yunzai) | 时雨🌌星空的 TRSS-Yunzai |
|
|
@@ -80,7 +80,7 @@
|
|
|
80
80
|
desc: 查看版本信息
|
|
81
81
|
- icon: 钓鱼
|
|
82
82
|
title: '#更新yuki-plugin'
|
|
83
|
-
desc: '系统指令更新yuki插件,
|
|
83
|
+
desc: '系统指令更新yuki插件,yunzaiJS需安装`@yunzaijs/system`'
|
|
84
84
|
- icon: pluie_lotus
|
|
85
85
|
title: '#强制更新yuki-plugin'
|
|
86
|
-
desc: '强制更新yuki插件,
|
|
86
|
+
desc: '强制更新yuki插件,yunzaiJS需安装`@yunzaijs/system`'
|
package/lib/apps/bilibili.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import JSON from 'json5';
|
|
2
2
|
import lodash from 'lodash';
|
|
3
|
-
import { Messages, Bot, Redis } from '
|
|
3
|
+
import { Messages, Bot, Redis } from 'yunzaijs';
|
|
4
4
|
import { BiliQuery } from '../models/bilibili/bilibili.query.js';
|
|
5
5
|
import { BiliTask } from '../models/bilibili/bilibili.task.js';
|
|
6
6
|
import Config from '../utils/config.js';
|
package/lib/apps/help.js
CHANGED
package/lib/apps/version.js
CHANGED
package/lib/apps/weibo.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
import { ConfigController, BOT_NAME } from '
|
|
2
|
+
import { ConfigController, BOT_NAME } from 'yunzaijs';
|
|
3
3
|
import Config from '../../utils/config.js';
|
|
4
4
|
import path from 'path';
|
|
5
5
|
import { _paths, createRequire } from '../../utils/paths.js';
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
import { BOT_NAME, ConfigController } from '
|
|
2
|
+
import { BOT_NAME, ConfigController } from 'yunzaijs';
|
|
3
3
|
import Config from '../../utils/config.js';
|
|
4
4
|
import path from 'path';
|
|
5
5
|
import { _paths, createRequire } from '../../utils/paths.js';
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
import { BOT_NAME, ConfigController } from '
|
|
2
|
+
import { BOT_NAME, ConfigController } from 'yunzaijs';
|
|
3
3
|
import Config from '../../utils/config.js';
|
|
4
4
|
import path from 'path';
|
|
5
5
|
import { _paths, createRequire } from '../../utils/paths.js';
|
package/lib/index.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import chalk from 'chalk';
|
|
2
|
-
import { applicationOptions, setBotTask, useEvent } from '
|
|
2
|
+
import { applicationOptions, setBotTask, useEvent } from 'yunzaijs';
|
|
3
3
|
import Config from './utils/config.js';
|
|
4
4
|
import path from 'path';
|
|
5
5
|
import { _paths } from './utils/paths.js';
|
package/lib/main.js
ADDED
|
@@ -0,0 +1,77 @@
|
|
|
1
|
+
class Murmur3 {
|
|
2
|
+
static MOD = 1n << 64n;
|
|
3
|
+
static C1 = 0x87c37b91114253d5n;
|
|
4
|
+
static C2 = 0x4cf5ad432745937fn;
|
|
5
|
+
static C3 = 0x52dce729n;
|
|
6
|
+
static C4 = 0x38495ab5n;
|
|
7
|
+
static R1 = 27n;
|
|
8
|
+
static R2 = 31n;
|
|
9
|
+
static R3 = 33n;
|
|
10
|
+
static M = 5n;
|
|
11
|
+
static hash(source, seed) {
|
|
12
|
+
let h1 = BigInt(seed);
|
|
13
|
+
let h2 = BigInt(seed);
|
|
14
|
+
let processed = 0;
|
|
15
|
+
for (let i = 0; i < source.length; i += 16) {
|
|
16
|
+
const chunk = source.slice(i, i + 16);
|
|
17
|
+
processed += chunk.length;
|
|
18
|
+
if (chunk.length === 16) {
|
|
19
|
+
const k1 = BigInt(chunk.slice(0, 8).reduce((acc, val, idx) => acc | (BigInt(val) << BigInt(8 * idx)), 0n));
|
|
20
|
+
const k2 = BigInt(chunk.slice(8).reduce((acc, val, idx) => acc | (BigInt(val) << BigInt(8 * idx)), 0n));
|
|
21
|
+
h1 ^= (Murmur3.rotateLeft((k1 * Murmur3.C1) % Murmur3.MOD, Murmur3.R2) * Murmur3.C2) % Murmur3.MOD;
|
|
22
|
+
h1 = ((Murmur3.rotateLeft(h1, Murmur3.R1) + h2) * Murmur3.M + Murmur3.C3) % Murmur3.MOD;
|
|
23
|
+
h2 ^= (Murmur3.rotateLeft((k2 * Murmur3.C2) % Murmur3.MOD, Murmur3.R3) * Murmur3.C1) % Murmur3.MOD;
|
|
24
|
+
h2 = ((Murmur3.rotateLeft(h2, Murmur3.R2) + h1) * Murmur3.M + Murmur3.C4) % Murmur3.MOD;
|
|
25
|
+
}
|
|
26
|
+
else {
|
|
27
|
+
let k1 = 0n;
|
|
28
|
+
let k2 = 0n;
|
|
29
|
+
for (let j = 0; j < chunk.length; j++) {
|
|
30
|
+
const byteVal = BigInt(chunk[j]);
|
|
31
|
+
if (j < 8) {
|
|
32
|
+
k1 |= byteVal << BigInt(8 * j);
|
|
33
|
+
}
|
|
34
|
+
else {
|
|
35
|
+
k2 |= byteVal << BigInt(8 * (j - 8));
|
|
36
|
+
}
|
|
37
|
+
}
|
|
38
|
+
k1 = (Murmur3.rotateLeft((k1 * Murmur3.C1) % Murmur3.MOD, Murmur3.R2) * Murmur3.C2) % Murmur3.MOD;
|
|
39
|
+
h1 ^= k1;
|
|
40
|
+
h2 ^= (Murmur3.rotateLeft((k2 * Murmur3.C2) % Murmur3.MOD, Murmur3.R3) * Murmur3.C1) % Murmur3.MOD;
|
|
41
|
+
}
|
|
42
|
+
}
|
|
43
|
+
h1 ^= BigInt(processed);
|
|
44
|
+
h2 ^= BigInt(processed);
|
|
45
|
+
h1 = (h1 + h2) % Murmur3.MOD;
|
|
46
|
+
h2 = (h2 + h1) % Murmur3.MOD;
|
|
47
|
+
h1 = Murmur3.fmix64(h1);
|
|
48
|
+
h2 = Murmur3.fmix64(h2);
|
|
49
|
+
h1 = (h1 + h2) % Murmur3.MOD;
|
|
50
|
+
h2 = (h2 + h1) % Murmur3.MOD;
|
|
51
|
+
return (h2 << BigInt(64)) | h1;
|
|
52
|
+
}
|
|
53
|
+
static rotateLeft(x, k) {
|
|
54
|
+
const index = Number(k);
|
|
55
|
+
const binStr = x.toString(2).padStart(64, '0');
|
|
56
|
+
return BigInt(`0b${binStr.slice(index)}${binStr.slice(0, index)}`);
|
|
57
|
+
}
|
|
58
|
+
static fmix64(k) {
|
|
59
|
+
const C1 = 0xff51afd7ed558ccdn;
|
|
60
|
+
const C2 = 0xc4ceb9fe1a85ec53n;
|
|
61
|
+
const R = 33;
|
|
62
|
+
let tmp = k;
|
|
63
|
+
tmp ^= tmp >> BigInt(R);
|
|
64
|
+
tmp = (tmp * C1) % Murmur3.MOD;
|
|
65
|
+
tmp ^= tmp >> BigInt(R);
|
|
66
|
+
tmp = (tmp * C2) % Murmur3.MOD;
|
|
67
|
+
tmp ^= tmp >> BigInt(R);
|
|
68
|
+
return tmp;
|
|
69
|
+
}
|
|
70
|
+
}
|
|
71
|
+
function gen_buvid_fp(uuid, seed) {
|
|
72
|
+
const source = new TextEncoder().encode(uuid);
|
|
73
|
+
const m = Murmur3.hash(source, seed);
|
|
74
|
+
return `${(m & (Murmur3.MOD - 1n)).toString(16)}${(m >> 64n).toString(16)}`;
|
|
75
|
+
}
|
|
76
|
+
|
|
77
|
+
export { gen_buvid_fp };
|
|
@@ -6,10 +6,11 @@ import { promisify } from 'node:util';
|
|
|
6
6
|
import path from 'path';
|
|
7
7
|
import QRCode from 'qrcode';
|
|
8
8
|
import YAML from 'yaml';
|
|
9
|
-
import { Segment, Bot, Redis } from '
|
|
9
|
+
import { Segment, Bot, Redis } from 'yunzaijs';
|
|
10
10
|
import { renderPage } from '../../utils/image.js';
|
|
11
11
|
import { _paths } from '../../utils/paths.js';
|
|
12
12
|
import { BiliApi } from './bilibili.api.js';
|
|
13
|
+
import { gen_buvid_fp } from './bilibili.buid.fp.js';
|
|
13
14
|
import { getBiliTicket } from './bilibili.ticket.js';
|
|
14
15
|
|
|
15
16
|
/**
|
|
@@ -606,6 +607,15 @@ async function postGateway(cookie) {
|
|
|
606
607
|
throw error;
|
|
607
608
|
}
|
|
608
609
|
}
|
|
610
|
+
/**生成buvid_fp
|
|
611
|
+
* @param {string} uuid
|
|
612
|
+
*/
|
|
613
|
+
async function get_buvid_fp(cookie) {
|
|
614
|
+
const uuid = await readSavedCookieItems(cookie, ['_uuid'], false);
|
|
615
|
+
const seedget = Math.floor(Math.random() * (60 - 1 + 1) + 1);
|
|
616
|
+
let buvidFp = gen_buvid_fp(uuid, seedget);
|
|
617
|
+
return `buvid_fp=${buvidFp};`;
|
|
618
|
+
}
|
|
609
619
|
/**
|
|
610
620
|
* 获取有效bili_ticket并添加到cookie
|
|
611
621
|
* @param {string} cookie
|
|
@@ -632,4 +642,4 @@ async function cookieWithBiliTicket(cookie) {
|
|
|
632
642
|
}
|
|
633
643
|
}
|
|
634
644
|
|
|
635
|
-
export { applyLoginQRCode, checkBiliLogin, cookieWithBiliTicket, exitBiliLogin, genUUID, gen_b_lsid, getNewTempCk, pollLoginQRCode, postGateway, readSavedCookieItems, readSavedCookieOtherItems, readSyncCookie, readTempCk, saveLocalBiliCk, saveLoginCookie, saveTempCk };
|
|
645
|
+
export { applyLoginQRCode, checkBiliLogin, cookieWithBiliTicket, exitBiliLogin, genUUID, gen_b_lsid, getNewTempCk, get_buvid_fp, pollLoginQRCode, postGateway, readSavedCookieItems, readSavedCookieOtherItems, readSyncCookie, readTempCk, saveLocalBiliCk, saveLoginCookie, saveTempCk };
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import QRCode from 'qrcode';
|
|
2
|
-
import { Redis, Bot, Segment } from '
|
|
2
|
+
import { Redis, Bot, Segment } from 'yunzaijs';
|
|
3
3
|
import Config from '../../utils/config.js';
|
|
4
4
|
import { renderPage } from '../../utils/image.js';
|
|
5
5
|
import { BiliGetWebData } from './bilibili.get.web.data.js';
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import QRCode from 'qrcode';
|
|
2
|
-
import { Redis, Bot, Segment } from '
|
|
2
|
+
import { Redis, Bot, Segment } from 'yunzaijs';
|
|
3
3
|
import Config from '../../utils/config.js';
|
|
4
4
|
import { renderPage } from '../../utils/image.js';
|
|
5
5
|
import { WeiboGetWebData } from './weibo.get.web.data.js';
|
package/lib/utils/config.js
CHANGED
|
@@ -61,7 +61,7 @@ class Config {
|
|
|
61
61
|
}
|
|
62
62
|
/**
|
|
63
63
|
* 通用获取配置文件数据方法
|
|
64
|
-
* @param typeDir 配置文件目录类型对应路径 defaultConfig: defaultConfig 或 config:
|
|
64
|
+
* @param typeDir 配置文件目录类型对应路径 defaultConfig: defaultConfig 或 config: yunzaijs/data/yuki-plugin/config
|
|
65
65
|
* @param appDir 配置app目录
|
|
66
66
|
* @param functionName 配置文件名称,不包含.yaml后缀
|
|
67
67
|
* @returns {object} 配置数据
|
|
@@ -77,7 +77,7 @@ class Config {
|
|
|
77
77
|
}
|
|
78
78
|
/**
|
|
79
79
|
* 获取配置文件路径
|
|
80
|
-
* @param typeDir 配置文件目录类型对应路径 defaultConfig: defaultConfig 或 config:
|
|
80
|
+
* @param typeDir 配置文件目录类型对应路径 defaultConfig: defaultConfig 或 config: yunzaijs/data/yuki-plugin/config
|
|
81
81
|
* @param appDir 配置app目录
|
|
82
82
|
* @param functionName 配置文件名称,不包含.yaml后缀
|
|
83
83
|
* @returns {string} 配置文件路径
|
|
@@ -93,7 +93,7 @@ class Config {
|
|
|
93
93
|
/**
|
|
94
94
|
* 监听配置文件的变化
|
|
95
95
|
* @param configFilePath 文件路径
|
|
96
|
-
* @param typeDir 配置文件目录类型对应路径 defaultConfig: defaultConfig 或 config:
|
|
96
|
+
* @param typeDir 配置文件目录类型对应路径 defaultConfig: defaultConfig 或 config: yunzaijs/data/yuki-plugin/config
|
|
97
97
|
* @param appDir 配置app目录
|
|
98
98
|
* @param functionName 配置文件名称,不包含.yaml后缀
|
|
99
99
|
*/
|
package/lib/utils/image.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
import { Picture } from '
|
|
2
|
+
import { Picture } from 'jsxp';
|
|
3
3
|
import { YukiPuppeteerRender } from './puppeteer.render.js';
|
|
4
4
|
import * as index from '../components/index.js';
|
|
5
5
|
|
|
@@ -35,9 +35,9 @@ class Image extends Picture {
|
|
|
35
35
|
const Page = index[page];
|
|
36
36
|
// 调用 yukiPuppeteerRender 进行截图操作
|
|
37
37
|
return this.yukiPuppeteerRender.yukiScreenshot(this.Com.compile({
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
38
|
+
path: page,
|
|
39
|
+
name: `${uid}.html`,
|
|
40
|
+
component: React.createElement(Page, { ...props }),
|
|
41
41
|
...ComponentCreateOpsion
|
|
42
42
|
}), ScreenshotOptions);
|
|
43
43
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "yz-yuki-plugin",
|
|
3
|
-
"version": "2.0.5-
|
|
3
|
+
"version": "2.0.5-4",
|
|
4
4
|
"description": "优纪插件,yunzaijs 关于 微博推送、B站推送 等功能的拓展插件",
|
|
5
5
|
"author": "snowtafir",
|
|
6
6
|
"type": "module",
|
|
@@ -11,13 +11,15 @@
|
|
|
11
11
|
"url": "https://github.com/snowtafir/yuki-plugin.git"
|
|
12
12
|
},
|
|
13
13
|
"scripts": {
|
|
14
|
-
"app": "
|
|
15
|
-
"
|
|
14
|
+
"app": "node lib/main.js",
|
|
15
|
+
"dev": "lvy dev --yunzai",
|
|
16
|
+
"build": "lvy build",
|
|
17
|
+
"view": "lvy dev --view",
|
|
18
|
+
"img-dev": "npx tsx watch --clear-screen=false jsxp.server.ts",
|
|
16
19
|
"render-test": "npx tsx ./render.test.ts",
|
|
17
|
-
"
|
|
18
|
-
"
|
|
19
|
-
"
|
|
20
|
-
"css-m": "tailwindcss -i ./src/input.css -o ./public/output.css -m",
|
|
20
|
+
"start": "pm2 startOrRestart pm2.config.cjs",
|
|
21
|
+
"stop": "pm2 stop pm2.config.cjs",
|
|
22
|
+
"delete": "pm2 delete pm2.config.cjs",
|
|
21
23
|
"format": "prettier --write .",
|
|
22
24
|
"check-format": "git diff --exit-code",
|
|
23
25
|
"prepare": "husky"
|
|
@@ -29,36 +31,23 @@
|
|
|
29
31
|
"debug": "^4.3.6",
|
|
30
32
|
"jsdom": "^24.1.1",
|
|
31
33
|
"json5": "^2.2.3",
|
|
34
|
+
"jsxp": "^1.0.4",
|
|
32
35
|
"lodash": "^4.17.21",
|
|
33
36
|
"md5": "^2.3.0",
|
|
34
37
|
"moment": "^2.30.1",
|
|
35
38
|
"node-fetch": "^3.3.2",
|
|
36
|
-
"puppeteer": "^23.3
|
|
39
|
+
"puppeteer": "^23.5.3",
|
|
37
40
|
"qrcode": "^1.5.4",
|
|
38
41
|
"react": "^18.3.1",
|
|
39
42
|
"react-dom": "^18.3.1",
|
|
40
|
-
"react-puppeteer": "^1.0.7",
|
|
41
43
|
"redis": "^4.7.0",
|
|
42
44
|
"yaml": "^2.5.1",
|
|
43
45
|
"yarn": "^1.19.1"
|
|
44
46
|
},
|
|
45
47
|
"devDependencies": {
|
|
46
|
-
"@babel/core": "^7.25.2",
|
|
47
|
-
"@babel/preset-env": "^7.25.4",
|
|
48
|
-
"@babel/preset-react": "^7.24.7",
|
|
49
|
-
"@babel/preset-typescript": "^7.24.7",
|
|
50
48
|
"@types/chalk": "2.2.0",
|
|
51
|
-
"@rollup/plugin-babel": "^6.0.4",
|
|
52
|
-
"@types/lodash": "^4.17.7",
|
|
53
|
-
"@rollup/plugin-commonjs": "^26.0.1",
|
|
54
|
-
"@rollup/plugin-image": "^3.0.3",
|
|
55
|
-
"@rollup/plugin-json": "^6.1.0",
|
|
56
|
-
"@rollup/plugin-node-resolve": "^15.2.3",
|
|
57
|
-
"@rollup/plugin-replace": "^5.0.7",
|
|
58
|
-
"@rollup/plugin-terser": "^0.4.4",
|
|
59
|
-
"@rollup/plugin-typescript": "^11.1.6",
|
|
60
|
-
"@types/rollup-plugin-auto-external": "^2.0.5",
|
|
61
49
|
"@types/jsdom": "^21.1.7",
|
|
50
|
+
"@types/lodash": "^4.17.7",
|
|
62
51
|
"@types/md5": "^2.3.5",
|
|
63
52
|
"@types/node": "^22.2.0",
|
|
64
53
|
"@types/node-fetch": "^2.6.11",
|
|
@@ -66,33 +55,29 @@
|
|
|
66
55
|
"@types/react": "^18.3.3",
|
|
67
56
|
"@types/react-dom": "^18.3.0",
|
|
68
57
|
"@types/yaml": "1.9.7",
|
|
58
|
+
"autoprefixer": "^10.4.20",
|
|
69
59
|
"axios": "^1.7.7",
|
|
70
|
-
"babel-plugin-module-resolver": "^5.0.2",
|
|
71
60
|
"chokidar": "^3.6.0",
|
|
72
61
|
"husky": "^9.1.6",
|
|
73
62
|
"jsdom": "^24.1.1",
|
|
74
63
|
"json5": "^2.2.3",
|
|
64
|
+
"jsxp": "^1.0.4",
|
|
75
65
|
"lodash": "^4.17.21",
|
|
66
|
+
"lvyjs": "^0.1.0",
|
|
76
67
|
"md5": "^2.3.0",
|
|
77
68
|
"node-fetch": "^3.3.2",
|
|
69
|
+
"postcss": "^8.4.47",
|
|
78
70
|
"prettier": "^3.3.3",
|
|
79
|
-
"puppeteer": "^23.3
|
|
71
|
+
"puppeteer": "^23.5.3",
|
|
80
72
|
"qrcode": "^1.5.4",
|
|
81
73
|
"react": "^18.3.1",
|
|
82
74
|
"react-dom": "^18.3.1",
|
|
83
|
-
"react-puppeteer": "^1.0.7",
|
|
84
75
|
"redis": "^4.7.0",
|
|
85
|
-
"
|
|
86
|
-
"rollup-plugin-auto-external": "^2.0.0",
|
|
87
|
-
"rollup-plugin-copy": "^3.5.0",
|
|
88
|
-
"rollup-plugin-dts": "^6.1.1",
|
|
89
|
-
"rollup-plugin-ignore": "^1.0.10",
|
|
90
|
-
"tailwindcss": "^3.4.9",
|
|
76
|
+
"tailwindcss": "^3.4.14",
|
|
91
77
|
"ts-node": "^10.9.2",
|
|
92
78
|
"tsx": "^4.19.0",
|
|
93
79
|
"typescript": "^5.5.4",
|
|
94
|
-
"
|
|
95
|
-
"yunzai-mys": "^1.0.6"
|
|
80
|
+
"yunzaijs": "^1.0.0-rc.4"
|
|
96
81
|
},
|
|
97
82
|
"files": [
|
|
98
83
|
"public",
|
|
@@ -113,7 +98,7 @@
|
|
|
113
98
|
}
|
|
114
99
|
},
|
|
115
100
|
"keywords": [
|
|
116
|
-
"
|
|
101
|
+
"yunzaijs"
|
|
117
102
|
],
|
|
118
103
|
"publishConfig": {
|
|
119
104
|
"registry": "https://registry.npmjs.org"
|
package/lib/apps/bilibili.d.ts
DELETED
package/lib/apps/help.d.ts
DELETED
package/lib/apps/index.d.ts
DELETED
package/lib/apps/version.d.ts
DELETED
package/lib/apps/weibo.d.ts
DELETED
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
|
-
type AccountProps = {
|
|
3
|
-
data: {
|
|
4
|
-
appName: string;
|
|
5
|
-
face?: string;
|
|
6
|
-
pendant?: string;
|
|
7
|
-
name?: string;
|
|
8
|
-
pubTs?: any;
|
|
9
|
-
category?: string;
|
|
10
|
-
};
|
|
11
|
-
};
|
|
12
|
-
declare const Account: React.FC<AccountProps>;
|
|
13
|
-
export default Account;
|
|
@@ -1,34 +0,0 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
|
-
export type MainProps = {
|
|
3
|
-
data: {
|
|
4
|
-
appName: string;
|
|
5
|
-
boxGrid?: boolean;
|
|
6
|
-
type?: string;
|
|
7
|
-
face?: string;
|
|
8
|
-
pendant?: string;
|
|
9
|
-
name?: string;
|
|
10
|
-
pubTs: any;
|
|
11
|
-
title?: string;
|
|
12
|
-
content?: string;
|
|
13
|
-
urlImgData?: string;
|
|
14
|
-
created?: any;
|
|
15
|
-
pics?: Array<any>;
|
|
16
|
-
category?: string;
|
|
17
|
-
orig?: {
|
|
18
|
-
data?: {
|
|
19
|
-
type?: string;
|
|
20
|
-
face?: string;
|
|
21
|
-
pendant?: string;
|
|
22
|
-
name?: string;
|
|
23
|
-
pubTs?: any;
|
|
24
|
-
title?: string;
|
|
25
|
-
content?: string;
|
|
26
|
-
urlImgData?: string;
|
|
27
|
-
created?: any;
|
|
28
|
-
pics?: string[];
|
|
29
|
-
category?: string;
|
|
30
|
-
};
|
|
31
|
-
};
|
|
32
|
-
};
|
|
33
|
-
};
|
|
34
|
-
export default function App({ data }: MainProps): React.JSX.Element;
|
|
@@ -1,5 +0,0 @@
|
|
|
1
|
-
declare const MainPage: typeof import("@/components/dynamic/MainPage").default;
|
|
2
|
-
declare const Help: typeof import("@/components/help/Help").default;
|
|
3
|
-
declare const LoginQrcodePage: typeof import("@/components/loginQrcode/Page").default;
|
|
4
|
-
declare const Version: typeof import("@/components/version/Version").default;
|
|
5
|
-
export { Help, LoginQrcodePage, MainPage, Version };
|