@annotorious/react 3.3.3 → 3.3.5
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/annotorious-react.es.js +37 -31
- package/dist/annotorious-react.es12.js +164 -177
- package/dist/annotorious-react.es12.js.map +1 -1
- package/dist/annotorious-react.es14.js +3 -3
- package/dist/annotorious-react.es16.js +3 -3
- package/dist/annotorious-react.es17.js +19 -127
- package/dist/annotorious-react.es17.js.map +1 -1
- package/dist/annotorious-react.es18.js +128 -6
- package/dist/annotorious-react.es18.js.map +1 -1
- package/dist/annotorious-react.es19.js +7 -2
- package/dist/annotorious-react.es19.js.map +1 -1
- package/dist/annotorious-react.es20.js +2 -11
- package/dist/annotorious-react.es20.js.map +1 -1
- package/dist/annotorious-react.es21.js +9 -124
- package/dist/annotorious-react.es21.js.map +1 -1
- package/dist/annotorious-react.es22.js +112 -452
- package/dist/annotorious-react.es22.js.map +1 -1
- package/dist/annotorious-react.es23.js +469 -0
- package/dist/annotorious-react.es23.js.map +1 -0
- package/dist/index.d.ts +1 -1
- package/dist/index.d.ts.map +1 -1
- package/package.json +10 -10
|
@@ -1,43 +1,49 @@
|
|
|
1
|
-
import { Annotorious as r, AnnotoriousContext as a, useAnnotation as
|
|
2
|
-
import { AnnotoriousPlugin as
|
|
1
|
+
import { Annotorious as r, AnnotoriousContext as a, useAnnotation as i, useAnnotationSelectAction as p, useAnnotationStore as s, useAnnotations as m, useAnnotator as u, useAnnotatorUser as A, useHover as S, useSelection as l, useViewportState as c } from "./annotorious-react.es2.js";
|
|
2
|
+
import { AnnotoriousPlugin as x } from "./annotorious-react.es3.js";
|
|
3
3
|
import { ImageAnnotationPopup as d } from "./annotorious-react.es4.js";
|
|
4
|
-
import { ImageAnnotator as
|
|
4
|
+
import { ImageAnnotator as I } from "./annotorious-react.es5.js";
|
|
5
5
|
/* empty css */
|
|
6
6
|
/* empty css */
|
|
7
|
-
import { Origin as
|
|
8
|
-
import { ShapeType as
|
|
9
|
-
import { OpenSeadragonAnnotator as
|
|
10
|
-
import { OpenSeadragonAnnotationPopup as
|
|
11
|
-
import { OpenSeadragonViewer as
|
|
7
|
+
import { Origin as O, UserSelectAction as V, createAnonymousGuest as P, createBody as w, defaultColorProvider as z } from "@annotorious/core";
|
|
8
|
+
import { ShapeType as G, W3CImageFormat as W, chainStyles as h, computeStyle as v, createImageAnnotator as U, parseFragmentSelector as B, parseSVGSelector as H, parseW3CImageAnnotation as T, serializeFragmentSelector as b, serializeSVGSelector as j, serializeW3CImageAnnotation as k } from "@annotorious/annotorious";
|
|
9
|
+
import { OpenSeadragonAnnotator as D, OpenSeadragonAnnotatorContext as E, useViewer as J } from "./annotorious-react.es8.js";
|
|
10
|
+
import { OpenSeadragonAnnotationPopup as L } from "./annotorious-react.es9.js";
|
|
11
|
+
import { OpenSeadragonViewer as N } from "./annotorious-react.es10.js";
|
|
12
12
|
export {
|
|
13
13
|
r as Annotorious,
|
|
14
14
|
a as AnnotoriousContext,
|
|
15
|
-
|
|
15
|
+
x as AnnotoriousPlugin,
|
|
16
16
|
d as ImageAnnotationPopup,
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
17
|
+
I as ImageAnnotator,
|
|
18
|
+
L as OpenSeadragonAnnotationPopup,
|
|
19
|
+
D as OpenSeadragonAnnotator,
|
|
20
|
+
E as OpenSeadragonAnnotatorContext,
|
|
21
|
+
N as OpenSeadragonViewer,
|
|
22
|
+
O as Origin,
|
|
23
|
+
G as ShapeType,
|
|
24
|
+
V as UserSelectAction,
|
|
25
|
+
W as W3CImageFormat,
|
|
26
|
+
h as chainStyles,
|
|
27
|
+
v as computeStyle,
|
|
28
|
+
P as createAnonymousGuest,
|
|
29
|
+
w as createBody,
|
|
30
|
+
U as createImageAnnotator,
|
|
31
|
+
z as defaultColorProvider,
|
|
32
|
+
B as parseFragmentSelector,
|
|
33
|
+
H as parseSVGSelector,
|
|
34
|
+
T as parseW3CImageAnnotation,
|
|
35
|
+
b as serializeFragmentSelector,
|
|
36
|
+
j as serializeSVGSelector,
|
|
37
|
+
k as serializeW3CImageAnnotation,
|
|
38
|
+
i as useAnnotation,
|
|
39
|
+
p as useAnnotationSelectAction,
|
|
40
|
+
s as useAnnotationStore,
|
|
41
|
+
m as useAnnotations,
|
|
42
|
+
u as useAnnotator,
|
|
37
43
|
A as useAnnotatorUser,
|
|
38
44
|
S as useHover,
|
|
39
|
-
|
|
40
|
-
|
|
45
|
+
l as useSelection,
|
|
46
|
+
J as useViewer,
|
|
41
47
|
c as useViewportState
|
|
42
48
|
};
|
|
43
49
|
//# sourceMappingURL=annotorious-react.es.js.map
|
|
@@ -1,269 +1,256 @@
|
|
|
1
|
-
import * as
|
|
2
|
-
import {
|
|
3
|
-
import { jsxs as
|
|
4
|
-
import { isElement as
|
|
5
|
-
import { getOverflowAncestors as
|
|
1
|
+
import * as r from "react";
|
|
2
|
+
import { useModernLayoutEffect as O, useEffectEvent as X } from "./annotorious-react.es17.js";
|
|
3
|
+
import { jsxs as Y, jsx as P } from "react/jsx-runtime";
|
|
4
|
+
import { isElement as I, getComputedStyle as q } from "./annotorious-react.es18.js";
|
|
5
|
+
import { getOverflowAncestors as pe } from "./annotorious-react.es18.js";
|
|
6
6
|
import "react-dom";
|
|
7
|
-
import { useFloating as
|
|
8
|
-
import { arrow as
|
|
9
|
-
const
|
|
10
|
-
...
|
|
11
|
-
}
|
|
12
|
-
|
|
13
|
-
const n = s.useRef(() => {
|
|
14
|
-
if (process.env.NODE_ENV !== "production")
|
|
15
|
-
throw new Error("Cannot call an event handler while rendering.");
|
|
16
|
-
});
|
|
17
|
-
return J(() => {
|
|
18
|
-
n.current = t;
|
|
19
|
-
}), s.useCallback(function() {
|
|
20
|
-
for (var c = arguments.length, e = new Array(c), o = 0; o < c; o++)
|
|
21
|
-
e[o] = arguments[o];
|
|
22
|
-
return n.current == null ? void 0 : n.current(...e);
|
|
23
|
-
}, []);
|
|
24
|
-
}
|
|
25
|
-
var M = typeof document < "u" ? k : q;
|
|
26
|
-
let y = !1, _ = 0;
|
|
7
|
+
import { useFloating as Q } from "./annotorious-react.es15.js";
|
|
8
|
+
import { arrow as he, flip as xe, inline as ve, offset as Ce, shift as we } from "./annotorious-react.es15.js";
|
|
9
|
+
const Z = {
|
|
10
|
+
...r
|
|
11
|
+
};
|
|
12
|
+
let V = !1, z = 0;
|
|
27
13
|
const W = () => (
|
|
28
14
|
// Ensure the id is unique with multiple independent versions of Floating UI
|
|
29
15
|
// on <React 18
|
|
30
|
-
"floating-ui-" + Math.random().toString(36).slice(2, 6) +
|
|
16
|
+
"floating-ui-" + Math.random().toString(36).slice(2, 6) + z++
|
|
31
17
|
);
|
|
32
|
-
function
|
|
33
|
-
const [t,
|
|
34
|
-
return
|
|
35
|
-
t == null &&
|
|
36
|
-
}, []),
|
|
37
|
-
|
|
18
|
+
function G() {
|
|
19
|
+
const [t, o] = r.useState(() => V ? W() : void 0);
|
|
20
|
+
return O(() => {
|
|
21
|
+
t == null && o(W());
|
|
22
|
+
}, []), r.useEffect(() => {
|
|
23
|
+
V = !0;
|
|
38
24
|
}, []), t;
|
|
39
25
|
}
|
|
40
|
-
const
|
|
41
|
-
let
|
|
42
|
-
process.env.NODE_ENV !== "production" && (
|
|
43
|
-
function
|
|
44
|
-
for (var t,
|
|
45
|
-
|
|
46
|
-
const
|
|
47
|
-
if (!((t =
|
|
48
|
-
var
|
|
49
|
-
(
|
|
26
|
+
const J = Z.useId, $ = J || G;
|
|
27
|
+
let M;
|
|
28
|
+
process.env.NODE_ENV !== "production" && (M = /* @__PURE__ */ new Set());
|
|
29
|
+
function K() {
|
|
30
|
+
for (var t, o = arguments.length, l = new Array(o), e = 0; e < o; e++)
|
|
31
|
+
l[e] = arguments[e];
|
|
32
|
+
const s = "Floating UI: " + l.join(" ");
|
|
33
|
+
if (!((t = M) != null && t.has(s))) {
|
|
34
|
+
var c;
|
|
35
|
+
(c = M) == null || c.add(s), console.warn(s);
|
|
50
36
|
}
|
|
51
37
|
}
|
|
52
|
-
function
|
|
53
|
-
for (var t,
|
|
54
|
-
|
|
55
|
-
const
|
|
56
|
-
if (!((t =
|
|
57
|
-
var
|
|
58
|
-
(
|
|
38
|
+
function _() {
|
|
39
|
+
for (var t, o = arguments.length, l = new Array(o), e = 0; e < o; e++)
|
|
40
|
+
l[e] = arguments[e];
|
|
41
|
+
const s = "Floating UI: " + l.join(" ");
|
|
42
|
+
if (!((t = M) != null && t.has(s))) {
|
|
43
|
+
var c;
|
|
44
|
+
(c = M) == null || c.add(s), console.error(s);
|
|
59
45
|
}
|
|
60
46
|
}
|
|
61
|
-
const
|
|
47
|
+
const ue = /* @__PURE__ */ r.forwardRef(function(o, l) {
|
|
62
48
|
const {
|
|
63
49
|
context: {
|
|
64
50
|
placement: e,
|
|
65
51
|
elements: {
|
|
66
|
-
floating:
|
|
52
|
+
floating: s
|
|
67
53
|
},
|
|
68
54
|
middlewareData: {
|
|
69
|
-
arrow:
|
|
55
|
+
arrow: c,
|
|
70
56
|
shift: u
|
|
71
57
|
}
|
|
72
58
|
},
|
|
73
|
-
width:
|
|
59
|
+
width: f = 14,
|
|
74
60
|
height: a = 7,
|
|
75
|
-
tipRadius:
|
|
61
|
+
tipRadius: F = 0,
|
|
76
62
|
strokeWidth: d = 0,
|
|
77
63
|
staticOffset: g,
|
|
78
|
-
stroke:
|
|
79
|
-
d:
|
|
64
|
+
stroke: R,
|
|
65
|
+
d: n,
|
|
80
66
|
style: {
|
|
81
67
|
transform: p,
|
|
82
|
-
...
|
|
68
|
+
...h
|
|
83
69
|
} = {},
|
|
84
|
-
...
|
|
85
|
-
} =
|
|
86
|
-
process.env.NODE_ENV !== "production" && (
|
|
87
|
-
const
|
|
88
|
-
if (
|
|
89
|
-
if (!
|
|
90
|
-
|
|
91
|
-
}, [
|
|
70
|
+
...x
|
|
71
|
+
} = o;
|
|
72
|
+
process.env.NODE_ENV !== "production" && (l || K("The `ref` prop is required for `FloatingArrow`."));
|
|
73
|
+
const v = $(), [E, i] = r.useState(!1);
|
|
74
|
+
if (O(() => {
|
|
75
|
+
if (!s) return;
|
|
76
|
+
q(s).direction === "rtl" && i(!0);
|
|
77
|
+
}, [s]), !s)
|
|
92
78
|
return null;
|
|
93
|
-
const [m,
|
|
79
|
+
const [m, D] = e.split("-"), N = m === "top" || m === "bottom";
|
|
94
80
|
let S = g;
|
|
95
|
-
(
|
|
96
|
-
const C = d * 2,
|
|
97
|
-
let
|
|
98
|
-
S && E && (
|
|
99
|
-
const
|
|
81
|
+
(N && u != null && u.x || !N && u != null && u.y) && (S = null);
|
|
82
|
+
const C = d * 2, b = C / 2, T = f / 2 * (F / -8 + 1), y = a / 2 * F / 4, w = !!n, k = S && D === "end" ? "bottom" : "top";
|
|
83
|
+
let A = S && D === "end" ? "right" : "left";
|
|
84
|
+
S && E && (A = D === "end" ? "left" : "right");
|
|
85
|
+
const B = (c == null ? void 0 : c.x) != null ? S || c.x : "", U = (c == null ? void 0 : c.y) != null ? S || c.y : "", L = n || "M0,0" + (" H" + f) + (" L" + (f - T) + "," + (a - y)) + (" Q" + f / 2 + "," + a + " " + T + "," + (a - y)) + " Z", H = {
|
|
100
86
|
top: w ? "rotate(180deg)" : "",
|
|
101
87
|
left: w ? "rotate(90deg)" : "rotate(-90deg)",
|
|
102
88
|
bottom: w ? "" : "rotate(180deg)",
|
|
103
89
|
right: w ? "rotate(-90deg)" : "rotate(90deg)"
|
|
104
90
|
}[m];
|
|
105
|
-
return /* @__PURE__ */
|
|
106
|
-
...
|
|
91
|
+
return /* @__PURE__ */ Y("svg", {
|
|
92
|
+
...x,
|
|
107
93
|
"aria-hidden": !0,
|
|
108
|
-
ref:
|
|
109
|
-
width: w ?
|
|
110
|
-
height:
|
|
111
|
-
viewBox: "0 0 " +
|
|
94
|
+
ref: l,
|
|
95
|
+
width: w ? f : f + C,
|
|
96
|
+
height: f,
|
|
97
|
+
viewBox: "0 0 " + f + " " + (a > f ? a : f),
|
|
112
98
|
style: {
|
|
113
99
|
position: "absolute",
|
|
114
100
|
pointerEvents: "none",
|
|
115
|
-
[
|
|
116
|
-
[
|
|
117
|
-
[m]:
|
|
118
|
-
transform: [
|
|
119
|
-
...
|
|
101
|
+
[A]: B,
|
|
102
|
+
[k]: U,
|
|
103
|
+
[m]: N || w ? "100%" : "calc(100% - " + C / 2 + "px)",
|
|
104
|
+
transform: [H, p].filter((j) => !!j).join(" "),
|
|
105
|
+
...h
|
|
120
106
|
},
|
|
121
|
-
children: [C > 0 && /* @__PURE__ */
|
|
122
|
-
clipPath: "url(#" +
|
|
107
|
+
children: [C > 0 && /* @__PURE__ */ P("path", {
|
|
108
|
+
clipPath: "url(#" + v + ")",
|
|
123
109
|
fill: "none",
|
|
124
|
-
stroke:
|
|
125
|
-
strokeWidth: C + (
|
|
126
|
-
d:
|
|
127
|
-
}), /* @__PURE__ */
|
|
128
|
-
stroke: C && !
|
|
129
|
-
d:
|
|
130
|
-
}), /* @__PURE__ */
|
|
131
|
-
id:
|
|
132
|
-
children: /* @__PURE__ */
|
|
133
|
-
x: -
|
|
134
|
-
y:
|
|
135
|
-
width:
|
|
136
|
-
height:
|
|
110
|
+
stroke: R,
|
|
111
|
+
strokeWidth: C + (n ? 0 : 1),
|
|
112
|
+
d: L
|
|
113
|
+
}), /* @__PURE__ */ P("path", {
|
|
114
|
+
stroke: C && !n ? x.fill : "none",
|
|
115
|
+
d: L
|
|
116
|
+
}), /* @__PURE__ */ P("clipPath", {
|
|
117
|
+
id: v,
|
|
118
|
+
children: /* @__PURE__ */ P("rect", {
|
|
119
|
+
x: -b,
|
|
120
|
+
y: b * (w ? -1 : 1),
|
|
121
|
+
width: f + C,
|
|
122
|
+
height: f
|
|
137
123
|
})
|
|
138
124
|
})]
|
|
139
125
|
});
|
|
140
126
|
});
|
|
141
|
-
function
|
|
127
|
+
function ee() {
|
|
142
128
|
const t = /* @__PURE__ */ new Map();
|
|
143
129
|
return {
|
|
144
|
-
emit(
|
|
130
|
+
emit(o, l) {
|
|
145
131
|
var e;
|
|
146
|
-
(e = t.get(
|
|
132
|
+
(e = t.get(o)) == null || e.forEach((s) => s(l));
|
|
147
133
|
},
|
|
148
|
-
on(
|
|
149
|
-
t.
|
|
134
|
+
on(o, l) {
|
|
135
|
+
t.has(o) || t.set(o, /* @__PURE__ */ new Set()), t.get(o).add(l);
|
|
150
136
|
},
|
|
151
|
-
off(
|
|
137
|
+
off(o, l) {
|
|
152
138
|
var e;
|
|
153
|
-
|
|
139
|
+
(e = t.get(o)) == null || e.delete(l);
|
|
154
140
|
}
|
|
155
141
|
};
|
|
156
142
|
}
|
|
157
|
-
const
|
|
143
|
+
const te = /* @__PURE__ */ r.createContext(null), ne = /* @__PURE__ */ r.createContext(null), oe = () => {
|
|
158
144
|
var t;
|
|
159
|
-
return ((t =
|
|
160
|
-
},
|
|
161
|
-
function
|
|
145
|
+
return ((t = r.useContext(te)) == null ? void 0 : t.id) || null;
|
|
146
|
+
}, re = () => r.useContext(ne);
|
|
147
|
+
function se(t) {
|
|
162
148
|
const {
|
|
163
|
-
open:
|
|
164
|
-
onOpenChange:
|
|
149
|
+
open: o = !1,
|
|
150
|
+
onOpenChange: l,
|
|
165
151
|
elements: e
|
|
166
|
-
} = t,
|
|
152
|
+
} = t, s = $(), c = r.useRef({}), [u] = r.useState(() => ee()), f = oe() != null;
|
|
167
153
|
if (process.env.NODE_ENV !== "production") {
|
|
168
|
-
const
|
|
169
|
-
|
|
154
|
+
const n = e.reference;
|
|
155
|
+
n && !I(n) && _("Cannot pass a virtual element to the `elements.reference` option,", "as it must be a real DOM element. Use `refs.setPositionReference()`", "instead.");
|
|
170
156
|
}
|
|
171
|
-
const [a,
|
|
172
|
-
|
|
173
|
-
open:
|
|
157
|
+
const [a, F] = r.useState(e.reference), d = X((n, p, h) => {
|
|
158
|
+
c.current.openEvent = n ? p : void 0, u.emit("openchange", {
|
|
159
|
+
open: n,
|
|
174
160
|
event: p,
|
|
175
|
-
reason:
|
|
176
|
-
nested:
|
|
177
|
-
}),
|
|
178
|
-
}), g =
|
|
179
|
-
setPositionReference:
|
|
180
|
-
}), []),
|
|
161
|
+
reason: h,
|
|
162
|
+
nested: f
|
|
163
|
+
}), l == null || l(n, p, h);
|
|
164
|
+
}), g = r.useMemo(() => ({
|
|
165
|
+
setPositionReference: F
|
|
166
|
+
}), []), R = r.useMemo(() => ({
|
|
181
167
|
reference: a || e.reference || null,
|
|
182
168
|
floating: e.floating || null,
|
|
183
169
|
domReference: e.reference
|
|
184
170
|
}), [a, e.reference, e.floating]);
|
|
185
|
-
return
|
|
186
|
-
dataRef:
|
|
187
|
-
open:
|
|
171
|
+
return r.useMemo(() => ({
|
|
172
|
+
dataRef: c,
|
|
173
|
+
open: o,
|
|
188
174
|
onOpenChange: d,
|
|
189
|
-
elements:
|
|
175
|
+
elements: R,
|
|
190
176
|
events: u,
|
|
191
|
-
floatingId:
|
|
177
|
+
floatingId: s,
|
|
192
178
|
refs: g
|
|
193
|
-
}), [
|
|
179
|
+
}), [o, d, R, u, s, g]);
|
|
194
180
|
}
|
|
195
|
-
function
|
|
181
|
+
function de(t) {
|
|
196
182
|
t === void 0 && (t = {});
|
|
197
183
|
const {
|
|
198
|
-
nodeId:
|
|
199
|
-
} = t,
|
|
184
|
+
nodeId: o
|
|
185
|
+
} = t, l = se({
|
|
200
186
|
...t,
|
|
201
187
|
elements: {
|
|
202
188
|
reference: null,
|
|
203
189
|
floating: null,
|
|
204
190
|
...t.elements
|
|
205
191
|
}
|
|
206
|
-
}), e = t.rootContext ||
|
|
207
|
-
|
|
192
|
+
}), e = t.rootContext || l, s = e.elements, [c, u] = r.useState(null), [f, a] = r.useState(null), d = (s == null ? void 0 : s.domReference) || c, g = r.useRef(null), R = re();
|
|
193
|
+
O(() => {
|
|
208
194
|
d && (g.current = d);
|
|
209
195
|
}, [d]);
|
|
210
|
-
const
|
|
196
|
+
const n = Q({
|
|
211
197
|
...t,
|
|
212
198
|
elements: {
|
|
213
|
-
...
|
|
214
|
-
...
|
|
215
|
-
reference:
|
|
199
|
+
...s,
|
|
200
|
+
...f && {
|
|
201
|
+
reference: f
|
|
216
202
|
}
|
|
217
203
|
}
|
|
218
|
-
}), p =
|
|
219
|
-
const m =
|
|
220
|
-
getBoundingClientRect: () =>
|
|
221
|
-
|
|
222
|
-
|
|
223
|
-
|
|
224
|
-
|
|
225
|
-
|
|
204
|
+
}), p = r.useCallback((i) => {
|
|
205
|
+
const m = I(i) ? {
|
|
206
|
+
getBoundingClientRect: () => i.getBoundingClientRect(),
|
|
207
|
+
getClientRects: () => i.getClientRects(),
|
|
208
|
+
contextElement: i
|
|
209
|
+
} : i;
|
|
210
|
+
a(m), n.refs.setReference(m);
|
|
211
|
+
}, [n.refs]), h = r.useCallback((i) => {
|
|
212
|
+
(I(i) || i === null) && (g.current = i, u(i)), (I(n.refs.reference.current) || n.refs.reference.current === null || // Don't allow setting virtual elements using the old technique back to
|
|
226
213
|
// `null` to support `positionReference` + an unstable `reference`
|
|
227
214
|
// callback ref.
|
|
228
|
-
|
|
229
|
-
}, [
|
|
230
|
-
...
|
|
231
|
-
setReference:
|
|
215
|
+
i !== null && !I(i)) && n.refs.setReference(i);
|
|
216
|
+
}, [n.refs]), x = r.useMemo(() => ({
|
|
217
|
+
...n.refs,
|
|
218
|
+
setReference: h,
|
|
232
219
|
setPositionReference: p,
|
|
233
220
|
domReference: g
|
|
234
|
-
}), [
|
|
235
|
-
...
|
|
221
|
+
}), [n.refs, h, p]), v = r.useMemo(() => ({
|
|
222
|
+
...n.elements,
|
|
236
223
|
domReference: d
|
|
237
|
-
}), [
|
|
238
|
-
...
|
|
224
|
+
}), [n.elements, d]), E = r.useMemo(() => ({
|
|
225
|
+
...n,
|
|
239
226
|
...e,
|
|
240
|
-
refs:
|
|
241
|
-
elements:
|
|
242
|
-
nodeId:
|
|
243
|
-
}), [
|
|
244
|
-
return
|
|
227
|
+
refs: x,
|
|
228
|
+
elements: v,
|
|
229
|
+
nodeId: o
|
|
230
|
+
}), [n, x, v, o, e]);
|
|
231
|
+
return O(() => {
|
|
245
232
|
e.dataRef.current.floatingContext = E;
|
|
246
|
-
const
|
|
247
|
-
|
|
248
|
-
}),
|
|
249
|
-
...
|
|
233
|
+
const i = R == null ? void 0 : R.nodesRef.current.find((m) => m.id === o);
|
|
234
|
+
i && (i.context = E);
|
|
235
|
+
}), r.useMemo(() => ({
|
|
236
|
+
...n,
|
|
250
237
|
context: E,
|
|
251
|
-
refs:
|
|
252
|
-
elements:
|
|
253
|
-
}), [
|
|
238
|
+
refs: x,
|
|
239
|
+
elements: v
|
|
240
|
+
}), [n, x, v, E]);
|
|
254
241
|
}
|
|
255
242
|
export {
|
|
256
|
-
|
|
257
|
-
|
|
258
|
-
|
|
259
|
-
|
|
260
|
-
|
|
261
|
-
|
|
262
|
-
|
|
263
|
-
|
|
264
|
-
|
|
265
|
-
|
|
266
|
-
|
|
267
|
-
|
|
243
|
+
ue as FloatingArrow,
|
|
244
|
+
he as arrow,
|
|
245
|
+
xe as flip,
|
|
246
|
+
pe as getOverflowAncestors,
|
|
247
|
+
ve as inline,
|
|
248
|
+
Ce as offset,
|
|
249
|
+
we as shift,
|
|
250
|
+
de as useFloating,
|
|
251
|
+
oe as useFloatingParentNodeId,
|
|
252
|
+
se as useFloatingRootContext,
|
|
253
|
+
re as useFloatingTree,
|
|
254
|
+
$ as useId
|
|
268
255
|
};
|
|
269
256
|
//# sourceMappingURL=annotorious-react.es12.js.map
|