@scoriiu/fenshot 0.1.5 → 0.1.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/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@scoriiu/fenshot",
3
- "version": "0.1.5",
4
- "description": "Screenshot in, FEN out. Chessboard recognition in the browser: detects the board in any screenshot or book diagram and reads the position with a CNN tile classifier.",
3
+ "version": "0.1.7",
4
+ "description": "Screenshot in, FEN out. Chessboard recognition in the browser: detects the board in any screenshot or book diagram and reads the position with a CNN tile classifier. With a chess-book reader for React (@scoriiu/fenshot/reader).",
5
5
  "type": "module",
6
6
  "main": "./dist/index.js",
7
7
  "types": "./dist/index.d.ts",
@@ -10,15 +10,22 @@
10
10
  "types": "./dist/index.d.ts",
11
11
  "import": "./dist/index.js"
12
12
  },
13
+ "./reader": {
14
+ "types": "./dist/reader/index.d.ts",
15
+ "import": "./dist/reader/index.js"
16
+ },
17
+ "./reader.css": "./dist/reader/reader.css",
13
18
  "./model/chess-tiles-v2.onnx": "./model/chess-tiles-v2.onnx"
14
19
  },
15
20
  "files": [
16
21
  "dist",
17
22
  "model"
18
23
  ],
19
- "sideEffects": false,
24
+ "sideEffects": [
25
+ "*.css"
26
+ ],
20
27
  "scripts": {
21
- "build": "tsc -p tsconfig.build.json",
28
+ "build": "tsc -p tsconfig.build.json && cp src/reader/reader.css dist/reader/reader.css",
22
29
  "test": "vitest run",
23
30
  "prepublishOnly": "npm run build && npm run test"
24
31
  },
@@ -26,14 +33,18 @@
26
33
  "access": "public"
27
34
  },
28
35
  "peerDependencies": {
29
- "onnxruntime-web": ">=1.17.0"
36
+ "onnxruntime-web": ">=1.17.0",
37
+ "pdfjs-dist": ">=5",
38
+ "react": ">=18"
30
39
  },
31
40
  "devDependencies": {
32
41
  "@types/pngjs": "^6.0.5",
33
42
  "onnxruntime-web": "1.26.0",
34
43
  "pngjs": "^7.0.0",
35
44
  "typescript": "^5.6.0",
36
- "vitest": "^3.0.0"
45
+ "vitest": "^3.0.0",
46
+ "@types/react": "^19.0.0",
47
+ "pdfjs-dist": "6.5.438"
37
48
  },
38
49
  "keywords": [
39
50
  "chess",
@@ -43,7 +54,10 @@
43
54
  "chessboard",
44
55
  "recognition",
45
56
  "onnx",
46
- "lichess"
57
+ "lichess",
58
+ "pdf",
59
+ "chess book",
60
+ "react"
47
61
  ],
48
62
  "author": "Kibitzo (https://kibitzo.com)",
49
63
  "license": "MIT",
@@ -54,5 +68,13 @@
54
68
  "homepage": "https://github.com/scoriiu/fenshot#readme",
55
69
  "bugs": {
56
70
  "url": "https://github.com/scoriiu/fenshot/issues"
71
+ },
72
+ "peerDependenciesMeta": {
73
+ "pdfjs-dist": {
74
+ "optional": true
75
+ },
76
+ "react": {
77
+ "optional": true
78
+ }
57
79
  }
58
80
  }