@floating-live/bilibili 0.16.17 → 0.17.0-alpha.1
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/LICENSE +1 -1
- package/{parser.js → dist/parser.js} +6 -0
- package/{plugin.js → dist/plugin.js} +4 -3
- package/package.json +17 -9
- package/plugin.json +7 -0
- /package/{index.d.ts → dist/index.d.ts} +0 -0
- /package/{index.js → dist/index.js} +0 -0
- /package/{parser.d.ts → dist/parser.d.ts} +0 -0
- /package/{plugin.d.ts → dist/plugin.d.ts} +0 -0
- /package/{room.d.ts → dist/room.d.ts} +0 -0
- /package/{room.js → dist/room.js} +0 -0
- /package/{types.d.ts → dist/types.d.ts} +0 -0
- /package/{types.js → dist/types.js} +0 -0
- /package/{utils → dist/utils}/crypto.d.ts +0 -0
- /package/{utils → dist/utils}/crypto.js +0 -0
- /package/{utils → dist/utils}/request.d.ts +0 -0
- /package/{utils → dist/utils}/request.js +0 -0
package/LICENSE
CHANGED
|
@@ -18,4 +18,4 @@ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
|
18
18
|
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
19
|
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
20
|
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
21
|
-
SOFTWARE.
|
|
21
|
+
SOFTWARE.
|
|
@@ -549,6 +549,9 @@ export function parseGetInfoByRoom(data) {
|
|
|
549
549
|
openStatus: 0,
|
|
550
550
|
opened: false,
|
|
551
551
|
connectionStatus: 0,
|
|
552
|
+
valid: true,
|
|
553
|
+
service: "",
|
|
554
|
+
serviceId: "bilibili",
|
|
552
555
|
};
|
|
553
556
|
}
|
|
554
557
|
/** 转换bilibili直播间信息为floating通用格式 */
|
|
@@ -580,6 +583,9 @@ export function parseRoomBaseInfo(data) {
|
|
|
580
583
|
openStatus: 0,
|
|
581
584
|
opened: false,
|
|
582
585
|
connectionStatus: 0,
|
|
586
|
+
valid: true,
|
|
587
|
+
service: "",
|
|
588
|
+
serviceId: "bilibili",
|
|
583
589
|
};
|
|
584
590
|
}
|
|
585
591
|
export function mergeLiveRoomData(...list) {
|
|
@@ -25,11 +25,12 @@ export class PluginBilibili extends BasePlugin {
|
|
|
25
25
|
this.room = null;
|
|
26
26
|
}
|
|
27
27
|
init(ctx) {
|
|
28
|
-
ctx.whenRegister("platform", (
|
|
28
|
+
ctx.whenRegister("platform", () => {
|
|
29
|
+
const platform = ctx.getPluginExposes("platform");
|
|
29
30
|
platform.register("bilibili", platformInfo, ctx.signal);
|
|
30
31
|
});
|
|
31
|
-
ctx.whenRegister("room", (
|
|
32
|
-
this.room = room;
|
|
32
|
+
ctx.whenRegister("room", () => {
|
|
33
|
+
this.room = ctx.getPluginExposes("room");
|
|
33
34
|
return () => {
|
|
34
35
|
this.room = null;
|
|
35
36
|
};
|
package/package.json
CHANGED
|
@@ -1,17 +1,19 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@floating-live/bilibili",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.17.0-alpha.1",
|
|
4
4
|
"type": "module",
|
|
5
|
-
"main": "index.js",
|
|
6
|
-
"types": "index.d.ts",
|
|
5
|
+
"main": "./dist/index.js",
|
|
6
|
+
"types": "./dist/index.d.ts",
|
|
7
7
|
"author": "Minteea",
|
|
8
8
|
"license": "MIT",
|
|
9
9
|
"scripts": {
|
|
10
10
|
"check": "tsc --noEmit",
|
|
11
|
-
"clear": "rimraf
|
|
11
|
+
"clear": "rimraf ./dist",
|
|
12
12
|
"build": "npm run clear && npm run check && tsc --build && tsc-alias",
|
|
13
13
|
"prepack": "npm run build",
|
|
14
|
-
"postpack": "npm run clear"
|
|
14
|
+
"postpack": "npm run clear",
|
|
15
|
+
"build:plugin": "vite build --config plugin.vite.config.ts",
|
|
16
|
+
"version": "floating-live-plugin-tools version && git add plugin.json"
|
|
15
17
|
},
|
|
16
18
|
"publishConfig": {
|
|
17
19
|
"access": "public"
|
|
@@ -22,16 +24,22 @@
|
|
|
22
24
|
"md5": "^2.3.0"
|
|
23
25
|
},
|
|
24
26
|
"devDependencies": {
|
|
27
|
+
"@floating-live/plugin-tools": "^0.1.0-alpha.5",
|
|
25
28
|
"@types/md5": "^2.3.0",
|
|
26
29
|
"@types/websocket": "^1.0.5",
|
|
27
30
|
"@types/ws": "^8.5.3",
|
|
28
|
-
"floating-live": "^0.
|
|
31
|
+
"floating-live": "^0.17.0-alpha.5",
|
|
29
32
|
"rimraf": "^3.0.2",
|
|
30
33
|
"tsc-alias": "^1.8.16",
|
|
31
|
-
"typescript": "^5.9.3"
|
|
34
|
+
"typescript": "^5.9.3",
|
|
35
|
+
"vite": "^8.0.11"
|
|
32
36
|
},
|
|
33
37
|
"peerDependencies": {
|
|
34
|
-
"floating-live": "
|
|
38
|
+
"floating-live": "0.17.0-alpha.5"
|
|
35
39
|
},
|
|
36
|
-
"
|
|
40
|
+
"files": [
|
|
41
|
+
"dist",
|
|
42
|
+
"plugin.json"
|
|
43
|
+
],
|
|
44
|
+
"gitHead": "eb7c02f5dba6b6abc223b747cdf391942ae9e734"
|
|
37
45
|
}
|
package/plugin.json
ADDED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|