@likecoin/epubcheck-ts 0.1.0 → 0.2.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/README.md CHANGED
@@ -6,14 +6,20 @@ A TypeScript port of [EPUBCheck](https://github.com/w3c/epubcheck) - the officia
6
6
  [![npm](https://img.shields.io/npm/v/%40likecoin%2Fepubcheck-ts)](https://www.npmjs.com/package/@likecoin/epubcheck-ts)
7
7
  [![License](https://img.shields.io/npm/l/%40likecoin%2Fepubcheck-ts)](./LICENSE)
8
8
 
9
+ > **Note**: This library is primarily developed for internal use at [3ook.com](https://3ook.com/about) and is built with AI-assisted development. While it has comprehensive test coverage (208 tests) and ~65% feature parity with Java EPUBCheck, it may not be suitable for mission-critical production workloads. For production environments requiring full EPUB validation, consider using the official [Java EPUBCheck](https://github.com/w3c/epubcheck). Contributions and feedback are welcome!
10
+
9
11
  ## Features
10
12
 
11
13
  - **Cross-platform**: Works in Node.js (18+) and modern browsers
12
- - **Partial EPUB validation**: Currently ~35% of EPUBCheck feature parity
14
+ - **Partial EPUB validation**: Currently ~65% of EPUBCheck feature parity
13
15
  - **Zero native dependencies**: Pure JavaScript/WebAssembly, no compilation required
14
16
  - **TypeScript first**: Full type definitions included
15
17
  - **Tree-shakable**: ESM with proper exports for optimal bundling
16
18
 
19
+ ## Try it Online
20
+
21
+ Try the live demo at **[likecoin.github.io/epubcheck-ts](https://likecoin.github.io/epubcheck-ts/)** - validate your EPUB files directly in the browser without uploading to any server.
22
+
17
23
  ## Installation
18
24
 
19
25
  ```bash
@@ -214,19 +220,20 @@ This library is a TypeScript port of the Java-based [EPUBCheck](https://github.c
214
220
 
215
221
  | Component | Status | Completeness | Notes |
216
222
  |-----------|--------|--------------|-------|
217
- | OCF Container | 🟡 Partial | ~40% | ZIP structure, mimetype, container.xml |
218
- | Package Document (OPF) | 🟡 Partial | ~40% | Metadata, manifest, spine, fallback chains |
219
- | Content Documents | 🟡 Partial | ~25% | XML well-formedness, XHTML structure |
220
- | Navigation Document | 🟡 Partial | ~30% | Nav structure, NCX validation |
223
+ | OCF Container | 🟡 Partial | ~70% | ZIP structure, mimetype (uncompressed check), container.xml |
224
+ | Package Document (OPF) | 🟡 Partial | ~70% | Metadata, manifest, spine, collections, version/date validation |
225
+ | Content Documents | 🟡 Partial | ~70% | XHTML structure, script/MathML/SVG detection, link validation |
226
+ | Navigation Document | 🟡 Partial | ~40% | Nav structure, NCX validation, remote link validation |
221
227
  | Schema Validation | 🟡 Partial | ~70% | RelaxNG, XSD, Schematron working |
222
- | CSS | 🔴 Basic | ~5% | Parser available, validation minimal |
228
+ | CSS | 🟡 Partial | ~50% | @font-face, @import, media overlay classes, position warnings |
229
+ | Cross-reference Validation | 🟡 Partial | ~75% | Reference tracking, fragment validation, undeclared resources |
230
+ | Accessibility Checks | 🟡 Partial | ~75% | Empty links, image alt, SVG titles, MathML alttext |
223
231
  | Media Overlays | ❌ Not Started | 0% | Planned |
224
- | Cross-reference Validation | 🔴 Basic | ~15% | Basic reference tracking |
225
- | Accessibility Checks | ❌ Not Started | 0% | Alt text, etc. |
232
+ | Media Validation | Not Started | 0% | Planned |
226
233
 
227
234
  Legend: 🟢 Complete | 🟡 Partial | 🔴 Basic | ❌ Not Started
228
235
 
229
- **Overall Progress: ~35% of Java EPUBCheck features**
236
+ **Overall Progress: ~65% of Java EPUBCheck features**
230
237
 
231
238
  See [PROJECT_STATUS.md](./PROJECT_STATUS.md) for detailed comparison.
232
239
 
@@ -306,7 +313,7 @@ Legend: ✅ Implemented
306
313
  | Aspect | epubcheck-ts | EPUBCheck (Java) |
307
314
  |--------|--------------|------------------|
308
315
  | Runtime | Node.js / Browser | JVM |
309
- | Feature Parity | ~35% | 100% |
316
+ | Feature Parity | ~65% | 100% |
310
317
  | Bundle Size | ~55KB JS + ~1.5MB WASM | ~15MB |
311
318
  | Installation | `npm install` | Download JAR |
312
319
  | Integration | Native JS/TS | CLI or Java API |
@@ -332,6 +339,10 @@ This is an independent TypeScript implementation inspired by the Java-based [EPU
332
339
  - [DAISY Consortium](https://daisy.org/) - Maintainers of EPUBCheck
333
340
  - [libxml2-wasm](https://github.com/jameslan/libxml2-wasm) - WebAssembly XML processing
334
341
 
342
+ ## Built by 3ook.com
343
+
344
+ This project is built and maintained by the [3ook.com](https://3ook.com/about) team. 3ook is a Web3 eBook platform where authors can publish EPUB ebooks and readers can collect them as digital assets. If you're an author looking to publish your ebook, check out [3ook.com](https://3ook.com/about).
345
+
335
346
  ## Related Projects
336
347
 
337
348
  - [EPUBCheck](https://github.com/w3c/epubcheck) - Official Java validator