@embedpdf/core-annotation 3.0.0-next.10 → 3.0.0-next.11
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/dist/index.cjs +10 -2
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +6 -1
- package/dist/index.d.ts +6 -1
- package/dist/index.js +10 -2
- package/dist/index.js.map +1 -1
- package/package.json +4 -4
package/dist/index.cjs
CHANGED
|
@@ -3021,7 +3021,7 @@ const canMove = (m, id) => {
|
|
|
3021
3021
|
* `locked` (and inert `/F` states) suppress them at runtime — a
|
|
3022
3022
|
* screen-anchored body keeps its handles: `noZoom`/`noRotate` exempt it from
|
|
3023
3023
|
* the display transform, they don't freeze its size or vertices. */
|
|
3024
|
-
const hasHandles = (a) => {
|
|
3024
|
+
const hasHandles = (m, a) => {
|
|
3025
3025
|
if (!annotTransformable(a) || textBound(a)) return false;
|
|
3026
3026
|
const c = capsFor(a.subtype);
|
|
3027
3027
|
return c.resizable || c.vertexEditable;
|
|
@@ -3088,7 +3088,7 @@ function hitTest(m, pon, p, geom, strokeMargin, pageBox, inert, view) {
|
|
|
3088
3088
|
};
|
|
3089
3089
|
}
|
|
3090
3090
|
}
|
|
3091
|
-
if (hasHandles(a)) {
|
|
3091
|
+
if (hasHandles(m, a)) {
|
|
3092
3092
|
for (const h of geomHandles(hitGeomOf(a, view))) if (Math.abs(h.at.x - p.x) <= geom.handleTol && Math.abs(h.at.y - p.y) <= geom.handleTol) return {
|
|
3093
3093
|
t: "handle",
|
|
3094
3094
|
id: a.id,
|
|
@@ -4853,6 +4853,14 @@ function setProps(m, patch) {
|
|
|
4853
4853
|
* COMMITTED member; uncommitted drafts just merge (their create draft carries
|
|
4854
4854
|
* the flags when it commits).
|
|
4855
4855
|
*/
|
|
4856
|
+
/**
|
|
4857
|
+
* The actions plane's session-visibility write (Hide actions, script
|
|
4858
|
+
* `annot.hidden`): merge per-id hidden overrides into the session overlay.
|
|
4859
|
+
* Pure session state — ZERO effects, no engine write, no authority. Hiding
|
|
4860
|
+
* clears transient engagement so no orphaned selection chrome or text editor
|
|
4861
|
+
* survives on an invisible annotation. Identity-preserving no-op when nothing
|
|
4862
|
+
* changes (plugin memo caches key on model identity).
|
|
4863
|
+
*/
|
|
4856
4864
|
function setFlags(m, patch, ids) {
|
|
4857
4865
|
const targets = ids ?? m.selected;
|
|
4858
4866
|
if (!targets.length) return [m, []];
|