@clearmist-labs/comic-archive-handler 1.0.0

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 ADDED
@@ -0,0 +1,82 @@
1
+ {
2
+ "name": "@clearmist-labs/comic-archive-handler",
3
+ "version": "1.0.0",
4
+ "description": "Detect, convert, and manipulate comic book archives: container conversion, edit metadata, image re-encoding, perceptual + content hashing.",
5
+ "keywords": [
6
+ "7z",
7
+ "archive",
8
+ "asar",
9
+ "cba",
10
+ "cbr",
11
+ "cbt",
12
+ "cbz",
13
+ "comic",
14
+ "comicinfo",
15
+ "metroninfo",
16
+ "phash",
17
+ "rar",
18
+ "tar",
19
+ "zip"
20
+ ],
21
+ "homepage": "https://github.com/Clearmist/comic-archive-handler",
22
+ "bugs": "https://github.com/Clearmist/comic-archive-handler/issues",
23
+ "license": "MIT",
24
+ "author": {
25
+ "name": "Matthew Sanders"
26
+ },
27
+ "repository": {
28
+ "type": "git",
29
+ "url": "git+https://github.com/Clearmist/comic-archive-handler.git"
30
+ },
31
+ "files": [
32
+ "dist",
33
+ "docs",
34
+ "schemas"
35
+ ],
36
+ "type": "module",
37
+ "main": "./dist/index.mjs",
38
+ "types": "./dist/index.d.mts",
39
+ "exports": {
40
+ ".": {
41
+ "types": "./dist/index.d.mts",
42
+ "import": "./dist/index.mjs"
43
+ },
44
+ "./package.json": "./package.json"
45
+ },
46
+ "publishConfig": {
47
+ "access": "public"
48
+ },
49
+ "scripts": {
50
+ "build": "tsdown",
51
+ "dev": "tsdown --watch",
52
+ "test": "vitest run",
53
+ "typecheck": "tsc --noEmit",
54
+ "lint": "oxlint .",
55
+ "format": "oxfmt . --write",
56
+ "check": "npm run typecheck && npm run lint && npx oxfmt . --check",
57
+ "prepublishOnly": "npm run build"
58
+ },
59
+ "dependencies": {
60
+ "7zip-bin-full": "^26.3.1",
61
+ "@electron/asar": "^4.3.0",
62
+ "fast-xml-parser": "^5.11.1",
63
+ "fflate": "^0.8.3",
64
+ "file-type": "^22.1.0",
65
+ "node-unrar-js": "^2.0.2",
66
+ "sharp": "^0.35.4",
67
+ "tar-stream": "^3.2.1",
68
+ "xmllint-wasm": "^5.3.0"
69
+ },
70
+ "devDependencies": {
71
+ "@types/node": "^22.20.2",
72
+ "@types/tar-stream": "^3.1.4",
73
+ "oxfmt": "^0.67.0",
74
+ "oxlint": "^1.82.0",
75
+ "tsdown": "^0.23.0",
76
+ "typescript": "^5.9.3",
77
+ "vitest": "^5.0.0"
78
+ },
79
+ "engines": {
80
+ "node": ">=18"
81
+ }
82
+ }
@@ -0,0 +1,127 @@
1
+ <?xml version="1.0" encoding="utf-8"?>
2
+ <xs:schema elementFormDefault="qualified" xmlns:xs="http://www.w3.org/2001/XMLSchema">
3
+ <xs:element name="ComicInfo" nillable="true" type="ComicInfo"/>
4
+ <xs:complexType name="ComicInfo">
5
+ <xs:sequence>
6
+ <xs:element minOccurs="0" maxOccurs="1" default="" name="Title" type="xs:string"/>
7
+ <xs:element minOccurs="0" maxOccurs="1" default="" name="Series" type="xs:string"/>
8
+ <xs:element minOccurs="0" maxOccurs="1" default="" name="Number" type="xs:string"/>
9
+ <xs:element minOccurs="0" maxOccurs="1" default="-1" name="Count" type="xs:int"/>
10
+ <xs:element minOccurs="0" maxOccurs="1" default="-1" name="Volume" type="xs:int"/>
11
+ <xs:element minOccurs="0" maxOccurs="1" default="" name="AlternateSeries" type="xs:string"/>
12
+ <xs:element minOccurs="0" maxOccurs="1" default="" name="AlternateNumber" type="xs:string"/>
13
+ <xs:element minOccurs="0" maxOccurs="1" default="-1" name="AlternateCount" type="xs:int"/>
14
+ <xs:element minOccurs="0" maxOccurs="1" default="" name="Summary" type="xs:string"/>
15
+ <xs:element minOccurs="0" maxOccurs="1" default="" name="Notes" type="xs:string"/>
16
+ <xs:element minOccurs="0" maxOccurs="1" default="-1" name="Year" type="xs:int"/>
17
+ <xs:element minOccurs="0" maxOccurs="1" default="-1" name="Month" type="xs:int"/>
18
+ <xs:element minOccurs="0" maxOccurs="1" default="-1" name="Day" type="xs:int"/>
19
+ <xs:element minOccurs="0" maxOccurs="1" default="" name="Writer" type="xs:string"/>
20
+ <xs:element minOccurs="0" maxOccurs="1" default="" name="Penciller" type="xs:string"/>
21
+ <xs:element minOccurs="0" maxOccurs="1" default="" name="Inker" type="xs:string"/>
22
+ <xs:element minOccurs="0" maxOccurs="1" default="" name="Colorist" type="xs:string"/>
23
+ <xs:element minOccurs="0" maxOccurs="1" default="" name="Letterer" type="xs:string"/>
24
+ <xs:element minOccurs="0" maxOccurs="1" default="" name="CoverArtist" type="xs:string"/>
25
+ <xs:element minOccurs="0" maxOccurs="1" default="" name="Editor" type="xs:string"/>
26
+ <xs:element minOccurs="0" maxOccurs="1" default="" name="Translator" type="xs:string"/>
27
+ <xs:element minOccurs="0" maxOccurs="1" default="" name="Publisher" type="xs:string"/>
28
+ <xs:element minOccurs="0" maxOccurs="1" default="" name="Imprint" type="xs:string"/>
29
+ <xs:element minOccurs="0" maxOccurs="1" default="" name="Genre" type="xs:string"/>
30
+ <xs:element minOccurs="0" maxOccurs="1" default="" name="Tags" type="xs:string"/>
31
+ <xs:element minOccurs="0" maxOccurs="1" default="" name="Web" type="xs:string"/>
32
+ <xs:element minOccurs="0" maxOccurs="1" default="0" name="PageCount" type="xs:int"/>
33
+ <xs:element minOccurs="0" maxOccurs="1" default="" name="LanguageISO" type="xs:string"/>
34
+ <xs:element minOccurs="0" maxOccurs="1" default="" name="Format" type="xs:string"/>
35
+ <xs:element minOccurs="0" maxOccurs="1" default="Unknown" name="BlackAndWhite" type="YesNo"/>
36
+ <xs:element minOccurs="0" maxOccurs="1" default="Unknown" name="Manga" type="Manga"/>
37
+ <xs:element minOccurs="0" maxOccurs="1" default="" name="Characters" type="xs:string"/>
38
+ <xs:element minOccurs="0" maxOccurs="1" default="" name="Teams" type="xs:string"/>
39
+ <xs:element minOccurs="0" maxOccurs="1" default="" name="Locations" type="xs:string"/>
40
+ <xs:element minOccurs="0" maxOccurs="1" default="" name="ScanInformation" type="xs:string"/>
41
+ <xs:element minOccurs="0" maxOccurs="1" default="" name="StoryArc" type="xs:string"/>
42
+ <xs:element minOccurs="0" maxOccurs="1" default="" name="StoryArcNumber" type="xs:string"/>
43
+ <xs:element minOccurs="0" maxOccurs="1" default="" name="SeriesGroup" type="xs:string"/>
44
+ <xs:element minOccurs="0" maxOccurs="1" default="Unknown" name="AgeRating" type="AgeRating"/>
45
+ <xs:element minOccurs="0" maxOccurs="1" name="Pages" type="ArrayOfComicPageInfo"/>
46
+ <xs:element minOccurs="0" maxOccurs="1" name="CommunityRating" type="Rating"/>
47
+ <xs:element minOccurs="0" maxOccurs="1" default="" name="MainCharacterOrTeam" type="xs:string"/>
48
+ <xs:element minOccurs="0" maxOccurs="1" default="" name="Review" type="xs:string"/>
49
+ <xs:element minOccurs="0" maxOccurs="1" default="" name="GTIN" type="xs:string"/>
50
+ </xs:sequence>
51
+ </xs:complexType>
52
+ <xs:simpleType name="YesNo">
53
+ <xs:restriction base="xs:string">
54
+ <xs:enumeration value="Unknown"/>
55
+ <xs:enumeration value="No"/>
56
+ <xs:enumeration value="Yes"/>
57
+ </xs:restriction>
58
+ </xs:simpleType>
59
+ <xs:simpleType name="Manga">
60
+ <xs:restriction base="xs:string">
61
+ <xs:enumeration value="Unknown"/>
62
+ <xs:enumeration value="No"/>
63
+ <xs:enumeration value="Yes"/>
64
+ <xs:enumeration value="YesAndRightToLeft"/>
65
+ </xs:restriction>
66
+ </xs:simpleType>
67
+ <xs:simpleType name="Rating">
68
+ <xs:restriction base="xs:decimal">
69
+ <xs:minInclusive value="0"/>
70
+ <xs:maxInclusive value="5"/>
71
+ <xs:fractionDigits value="1"/>
72
+ </xs:restriction>
73
+ </xs:simpleType>
74
+ <xs:simpleType name="AgeRating">
75
+ <xs:restriction base="xs:string">
76
+ <xs:enumeration value="Unknown"/>
77
+ <xs:enumeration value="Adults Only 18+"/>
78
+ <xs:enumeration value="Early Childhood"/>
79
+ <xs:enumeration value="Everyone"/>
80
+ <xs:enumeration value="Everyone 10+"/>
81
+ <xs:enumeration value="G"/>
82
+ <xs:enumeration value="Kids to Adults"/>
83
+ <xs:enumeration value="M"/>
84
+ <xs:enumeration value="MA15+"/>
85
+ <xs:enumeration value="Mature 17+"/>
86
+ <xs:enumeration value="PG"/>
87
+ <xs:enumeration value="R18+"/>
88
+ <xs:enumeration value="Rating Pending"/>
89
+ <xs:enumeration value="Teen"/>
90
+ <xs:enumeration value="X18+"/>
91
+ </xs:restriction>
92
+ </xs:simpleType>
93
+ <xs:complexType name="ArrayOfComicPageInfo">
94
+ <xs:sequence>
95
+ <xs:element minOccurs="0" maxOccurs="unbounded" name="Page" nillable="true" type="ComicPageInfo"/>
96
+ </xs:sequence>
97
+ </xs:complexType>
98
+ <xs:complexType name="ComicPageInfo">
99
+ <xs:attribute name="Image" type="xs:int" use="required"/>
100
+ <xs:attribute default="Story" name="Type" type="ComicPageType"/>
101
+ <xs:attribute default="false" name="DoublePage" type="xs:boolean"/>
102
+ <xs:attribute default="0" name="ImageSize" type="xs:long"/>
103
+ <xs:attribute default="" name="Key" type="xs:string"/>
104
+ <xs:attribute default="" name="Bookmark" type="xs:string"/>
105
+ <xs:attribute default="-1" name="ImageWidth" type="xs:int"/>
106
+ <xs:attribute default="-1" name="ImageHeight" type="xs:int"/>
107
+ </xs:complexType>
108
+ <xs:simpleType name="ComicPageType">
109
+ <xs:list>
110
+ <xs:simpleType>
111
+ <xs:restriction base="xs:string">
112
+ <xs:enumeration value="FrontCover"/>
113
+ <xs:enumeration value="InnerCover"/>
114
+ <xs:enumeration value="Roundup"/>
115
+ <xs:enumeration value="Story"/>
116
+ <xs:enumeration value="Advertisement"/>
117
+ <xs:enumeration value="Editorial"/>
118
+ <xs:enumeration value="Letters"/>
119
+ <xs:enumeration value="Preview"/>
120
+ <xs:enumeration value="BackCover"/>
121
+ <xs:enumeration value="Other"/>
122
+ <xs:enumeration value="Deleted"/>
123
+ </xs:restriction>
124
+ </xs:simpleType>
125
+ </xs:list>
126
+ </xs:simpleType>
127
+ </xs:schema>