@docx-editor.dev/editor-api 2.1.2 → 2.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.
@@ -1571,6 +1571,11 @@ declare class ObjectPath {
1571
1571
  * Both refusals are `InvalidObjectPath` on purpose: from a consumer's side "this object was
1572
1572
  * released" and "this object is still a promise" are the same mistake — using an object the
1573
1573
  * runtime cannot address yet or any more — and the `target` says which object it was.
1574
+ *
1575
+ * THE CODE IS ONE THING AND THE MESSAGE IS ANOTHER. The two states have different fixes — a
1576
+ * promise needs a `sync()`, a released object needs to have been tracked — so the sentence in
1577
+ * `errors.ts` names both. It described only the released half for a while, which sent a
1578
+ * consumer holding a perfectly good promised object off to `trackedObjects.add(...)`.
1574
1579
  */
1575
1580
  address(): ObjectAddress;
1576
1581
  /** The handle to address this object with. Refused for anything that is not handle-shaped. */
@@ -1715,7 +1720,14 @@ type DocxEditorErrorCode =
1715
1720
  'PropertyNotLoaded'
1716
1721
  /** A `ClientResult` value was read before the sync that fills it. */
1717
1722
  | 'ValueNotLoaded'
1718
- /** The object is no longer addressable: its run ended and it was not tracked. */
1723
+ /**
1724
+ * The object cannot be addressed, in either of the two ways that happens.
1725
+ *
1726
+ * NOT YET: an item accessor answers a proxy the read that names it has not answered for, and it
1727
+ * becomes usable at the next `sync()`. NOT ANY MORE: its run ended and nothing tracked it, which
1728
+ * is terminal. One code because from a consumer's side both are "this object cannot be used
1729
+ * here"; the message says which one, because the fix for one is not the fix for the other.
1730
+ */
1719
1731
  | 'InvalidObjectPath'
1720
1732
  /** The object still belongs to a run that has not finished, so it cannot be handed over. */
1721
1733
  | 'ObjectInUse'
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@docx-editor.dev/editor-api",
3
- "version": "2.1.2",
3
+ "version": "2.2.0",
4
4
  "description": "Document automation for DOCX: a batching object model that drives a document from a server or from an editor already open in a page",
5
5
  "sideEffects": false,
6
6
  "main": "./dist/index.js",
@@ -73,6 +73,6 @@
73
73
  "access": "public"
74
74
  },
75
75
  "dependencies": {
76
- "@docx-editor.dev/core": "^2.1.2"
76
+ "@docx-editor.dev/core": "^2.2.0"
77
77
  }
78
78
  }