@apocaliss92/scrypted-reolink-native 0.4.6 → 0.4.7
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/dist/main.nodejs.js +1 -1
- package/dist/plugin.zip +0 -0
- package/package.json +51 -52
- package/src/main.ts +13 -0
package/dist/plugin.zip
CHANGED
|
Binary file
|
package/package.json
CHANGED
|
@@ -1,54 +1,53 @@
|
|
|
1
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
|
-
}
|
|
2
|
+
"name": "@apocaliss92/scrypted-reolink-native",
|
|
3
|
+
"version": "0.4.7",
|
|
4
|
+
"description": "Use any reolink camera with Scrypted, even older/unsupported models without HTTP protocol support",
|
|
5
|
+
"author": "@apocaliss92",
|
|
6
|
+
"license": "Apache",
|
|
7
|
+
"repository": {
|
|
8
|
+
"type": "git",
|
|
9
|
+
"url": "https://github.com/apocaliss92/scrypted-reolink-native"
|
|
10
|
+
},
|
|
11
|
+
"scripts": {
|
|
12
|
+
"build:lib": "./build-lib.sh",
|
|
13
|
+
"scrypted-setup-project": "scrypted-setup-project",
|
|
14
|
+
"prescrypted-setup-project": "scrypted-package-json",
|
|
15
|
+
"build": "scrypted-webpack",
|
|
16
|
+
"prepublishOnly": "NODE_ENV=production scrypted-webpack",
|
|
17
|
+
"prescrypted-vscode-launch": "scrypted-webpack",
|
|
18
|
+
"scrypted-vscode-launch": "scrypted-deploy-debug",
|
|
19
|
+
"scrypted-deploy-debug": "scrypted-deploy-debug",
|
|
20
|
+
"scrypted-debug": "scrypted-debug",
|
|
21
|
+
"scrypted-deploy": "scrypted-deploy",
|
|
22
|
+
"scrypted-readme": "scrypted-readme",
|
|
23
|
+
"scrypted-package-json": "scrypted-package-json"
|
|
24
|
+
},
|
|
25
|
+
"keywords": [
|
|
26
|
+
"scrypted",
|
|
27
|
+
"plugin",
|
|
28
|
+
"reolink",
|
|
29
|
+
"native",
|
|
30
|
+
"camera"
|
|
31
|
+
],
|
|
32
|
+
"scrypted": {
|
|
33
|
+
"name": "Reolink Native",
|
|
34
|
+
"type": "DeviceProvider",
|
|
35
|
+
"interfaces": [
|
|
36
|
+
"ScryptedSystemDevice",
|
|
37
|
+
"ScryptedDeviceCreator",
|
|
38
|
+
"DeviceProvider",
|
|
39
|
+
"DeviceCreator",
|
|
40
|
+
"Settings",
|
|
41
|
+
"HttpRequestHandler"
|
|
42
|
+
]
|
|
43
|
+
},
|
|
44
|
+
"dependencies": {
|
|
45
|
+
"@scrypted/common": "file:../../scrypted/common",
|
|
46
|
+
"@scrypted/rtsp": "file:../../scrypted/plugins/rtsp",
|
|
47
|
+
"@scrypted/sdk": "^0.3.118",
|
|
48
|
+
"@apocaliss92/reolink-baichuan-js": "file:./reolink-baichuan-js"
|
|
49
|
+
},
|
|
50
|
+
"devDependencies": {
|
|
51
|
+
"@types/node": "^22.0.2"
|
|
52
|
+
}
|
|
54
53
|
}
|
package/src/main.ts
CHANGED
|
@@ -1,3 +1,16 @@
|
|
|
1
|
+
// Polyfill for File class if not available (required by undici in some Node.js environments)
|
|
2
|
+
if (typeof globalThis.File === "undefined") {
|
|
3
|
+
(globalThis as any).File = class File extends Blob {
|
|
4
|
+
name: string;
|
|
5
|
+
lastModified: number;
|
|
6
|
+
constructor(chunks: BlobPart[], name: string, options?: FilePropertyBag) {
|
|
7
|
+
super(chunks, options);
|
|
8
|
+
this.name = name;
|
|
9
|
+
this.lastModified = options?.lastModified ?? Date.now();
|
|
10
|
+
}
|
|
11
|
+
};
|
|
12
|
+
}
|
|
13
|
+
|
|
1
14
|
import sdk, {
|
|
2
15
|
DeviceCreator,
|
|
3
16
|
DeviceCreatorSettings,
|