wordinweb 0.1.21 → 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 +21 -2
- package/dist/chunk-XGTWJMDG.js +38208 -0
- package/dist/chunk-XGTWJMDG.js.map +1 -0
- package/dist/collab.d.ts +1281 -0
- package/dist/collab.js +4909 -0
- package/dist/collab.js.map +1 -0
- package/dist/index-C2J9egkh.d.ts +4314 -0
- package/dist/index.d.ts +2 -2397
- package/dist/index.js +13 -35595
- package/dist/index.js.map +1 -1
- package/package.json +13 -3
package/README.md
CHANGED
|
@@ -297,6 +297,23 @@ when a host needs a narrowly scoped style override.
|
|
|
297
297
|
|
|
298
298
|
WordInWeb never converts the document to flowing HTML. It parses the OOXML into a typed model, runs a layout engine that breaks lines with real canvas metrics and paginates like Word, and renders each primitive as one absolutely-positioned element, so the browser does zero reflow. Editing mutates the retained XML tree and re-serializes only the parts it models, leaving everything else byte-for-byte intact.
|
|
299
299
|
|
|
300
|
+
## Collaboration
|
|
301
|
+
|
|
302
|
+
React collaboration ships as the separate `wordinweb/collab` entry:
|
|
303
|
+
|
|
304
|
+
```tsx
|
|
305
|
+
import { CollabEditor, IndexedDbBundleStore } from "wordinweb/collab";
|
|
306
|
+
```
|
|
307
|
+
|
|
308
|
+
The Node host ships as `@wordinweb/server`. Browser-only applications do not
|
|
309
|
+
install it, and the main `wordinweb` entry has no path to either collaboration
|
|
310
|
+
entry.
|
|
311
|
+
|
|
312
|
+
The [anonymous sharing example][collab-example] documents a complete encrypted
|
|
313
|
+
deployment.
|
|
314
|
+
|
|
315
|
+
[collab-example]: https://github.com/theRealestAEP/wordinweb/tree/main/examples/anon-share
|
|
316
|
+
|
|
300
317
|
## Fonts
|
|
301
318
|
|
|
302
319
|
Text is measured on a canvas before layout, so line breaks depend on the real font metrics. For Word parity, register the bundled OFL substitutes in your app entry:
|
|
@@ -330,8 +347,10 @@ When the browser can't render a requested face, `onMissingFonts` reports it so y
|
|
|
330
347
|
|
|
331
348
|
```bash
|
|
332
349
|
npm install
|
|
333
|
-
npm
|
|
334
|
-
npm run
|
|
350
|
+
npm run build # build all published packages
|
|
351
|
+
npm run typecheck # type-check packages and the example
|
|
352
|
+
npm test # build and run package and example unit tests
|
|
353
|
+
npm run demo # build and open the collaboration demo
|
|
335
354
|
```
|
|
336
355
|
|
|
337
356
|
## Rendering parity
|