@annotorious/react-manifold 3.0.0-rc.19.1 → 3.0.0-rc.20

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.
Files changed (41) hide show
  1. package/dist/AnnotoriousManifoldInstance.d.ts.map +1 -1
  2. package/dist/annotorious-react-manifold.es10.js +7 -8
  3. package/dist/annotorious-react-manifold.es10.js.map +1 -1
  4. package/dist/annotorious-react-manifold.es11.js +16 -7
  5. package/dist/annotorious-react-manifold.es11.js.map +1 -1
  6. package/dist/annotorious-react-manifold.es12.js +2 -16
  7. package/dist/annotorious-react-manifold.es12.js.map +1 -1
  8. package/dist/annotorious-react-manifold.es13.js +30 -2
  9. package/dist/annotorious-react-manifold.es13.js.map +1 -1
  10. package/dist/annotorious-react-manifold.es14.js +590 -21
  11. package/dist/annotorious-react-manifold.es14.js.map +1 -1
  12. package/dist/annotorious-react-manifold.es15.js +2 -599
  13. package/dist/annotorious-react-manifold.es15.js.map +1 -1
  14. package/dist/annotorious-react-manifold.es16.js +2 -2
  15. package/dist/annotorious-react-manifold.es17.js +6 -2
  16. package/dist/annotorious-react-manifold.es17.js.map +1 -1
  17. package/dist/annotorious-react-manifold.es18.js +2 -6
  18. package/dist/annotorious-react-manifold.es18.js.map +1 -1
  19. package/dist/annotorious-react-manifold.es19.js +30 -2
  20. package/dist/annotorious-react-manifold.es19.js.map +1 -1
  21. package/dist/annotorious-react-manifold.es2.js +12 -13
  22. package/dist/annotorious-react-manifold.es2.js.map +1 -1
  23. package/dist/annotorious-react-manifold.es20.js +590 -21
  24. package/dist/annotorious-react-manifold.es20.js.map +1 -1
  25. package/dist/annotorious-react-manifold.es21.js +2 -599
  26. package/dist/annotorious-react-manifold.es21.js.map +1 -1
  27. package/dist/annotorious-react-manifold.es22.js +2 -2
  28. package/dist/annotorious-react-manifold.es22.js.map +1 -1
  29. package/dist/annotorious-react-manifold.es4.js +2 -3
  30. package/dist/annotorious-react-manifold.es4.js.map +1 -1
  31. package/dist/annotorious-react-manifold.es6.js +3 -4
  32. package/dist/annotorious-react-manifold.es6.js.map +1 -1
  33. package/dist/annotorious-react-manifold.es7.js +3 -3
  34. package/dist/annotorious-react-manifold.es8.js +14 -14
  35. package/dist/annotorious-react-manifold.es8.js.map +1 -1
  36. package/dist/annotorious-react-manifold.es9.js +13 -1385
  37. package/dist/annotorious-react-manifold.es9.js.map +1 -1
  38. package/dist/synchronizeInstances.d.ts.map +1 -1
  39. package/package.json +9 -6
  40. package/dist/annotorious-react-manifold.es23.js +0 -5
  41. package/dist/annotorious-react-manifold.es23.js.map +0 -1
@@ -1 +1 @@
1
- {"version":3,"file":"annotorious-react-manifold.es21.js","sources":["../../annotorious-react/dist/annotorious-react.es19.js"],"sourcesContent":["import { __exports as R } from \"./annotorious-react.es21.js\";\nimport tr from \"react\";\n/**\n * @license React\n * react-jsx-runtime.development.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\nvar he;\nfunction ir() {\n return he ? R : (he = 1, process.env.NODE_ENV !== \"production\" && function() {\n var Ee = tr, x = Symbol.for(\"react.element\"), ye = Symbol.for(\"react.portal\"), _ = Symbol.for(\"react.fragment\"), U = Symbol.for(\"react.strict_mode\"), N = Symbol.for(\"react.profiler\"), B = Symbol.for(\"react.provider\"), q = Symbol.for(\"react.context\"), T = Symbol.for(\"react.forward_ref\"), k = Symbol.for(\"react.suspense\"), D = Symbol.for(\"react.suspense_list\"), C = Symbol.for(\"react.memo\"), F = Symbol.for(\"react.lazy\"), me = Symbol.for(\"react.offscreen\"), G = Symbol.iterator, Re = \"@@iterator\";\n function _e(e) {\n if (e === null || typeof e != \"object\")\n return null;\n var r = G && e[G] || e[Re];\n return typeof r == \"function\" ? r : null;\n }\n var b = Ee.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED;\n function l(e) {\n {\n for (var r = arguments.length, t = new Array(r > 1 ? r - 1 : 0), n = 1; n < r; n++)\n t[n - 1] = arguments[n];\n Te(\"error\", e, t);\n }\n }\n function Te(e, r, t) {\n {\n var n = b.ReactDebugCurrentFrame, o = n.getStackAddendum();\n o !== \"\" && (r += \"%s\", t = t.concat([o]));\n var u = t.map(function(i) {\n return String(i);\n });\n u.unshift(\"Warning: \" + r), Function.prototype.apply.call(console[e], console, u);\n }\n }\n var Ce = !1, Pe = !1, we = !1, Oe = !1, Se = !1, z;\n z = Symbol.for(\"react.module.reference\");\n function je(e) {\n return !!(typeof e == \"string\" || typeof e == \"function\" || e === _ || e === N || Se || e === U || e === k || e === D || Oe || e === me || Ce || Pe || we || typeof e == \"object\" && e !== null && (e.$$typeof === F || e.$$typeof === C || e.$$typeof === B || e.$$typeof === q || e.$$typeof === T || // This needs to include all possible module reference object\n // types supported by any Flight configuration anywhere since\n // we don't know which Flight build this will end up being used\n // with.\n e.$$typeof === z || e.getModuleId !== void 0));\n }\n function xe(e, r, t) {\n var n = e.displayName;\n if (n)\n return n;\n var o = r.displayName || r.name || \"\";\n return o !== \"\" ? t + \"(\" + o + \")\" : t;\n }\n function J(e) {\n return e.displayName || \"Context\";\n }\n function d(e) {\n if (e == null)\n return null;\n if (typeof e.tag == \"number\" && l(\"Received an unexpected object in getComponentNameFromType(). This is likely a bug in React. Please file an issue.\"), typeof e == \"function\")\n return e.displayName || e.name || null;\n if (typeof e == \"string\")\n return e;\n switch (e) {\n case _:\n return \"Fragment\";\n case ye:\n return \"Portal\";\n case N:\n return \"Profiler\";\n case U:\n return \"StrictMode\";\n case k:\n return \"Suspense\";\n case D:\n return \"SuspenseList\";\n }\n if (typeof e == \"object\")\n switch (e.$$typeof) {\n case q:\n var r = e;\n return J(r) + \".Consumer\";\n case B:\n var t = e;\n return J(t._context) + \".Provider\";\n case T:\n return xe(e, e.render, \"ForwardRef\");\n case C:\n var n = e.displayName || null;\n return n !== null ? n : d(e.type) || \"Memo\";\n case F: {\n var o = e, u = o._payload, i = o._init;\n try {\n return d(i(u));\n } catch {\n return null;\n }\n }\n }\n return null;\n }\n var g = Object.assign, y = 0, K, H, X, Z, Q, ee, re;\n function te() {\n }\n te.__reactDisabledLog = !0;\n function ke() {\n {\n if (y === 0) {\n K = console.log, H = console.info, X = console.warn, Z = console.error, Q = console.group, ee = console.groupCollapsed, re = console.groupEnd;\n var e = {\n configurable: !0,\n enumerable: !0,\n value: te,\n writable: !0\n };\n Object.defineProperties(console, {\n info: e,\n log: e,\n warn: e,\n error: e,\n group: e,\n groupCollapsed: e,\n groupEnd: e\n });\n }\n y++;\n }\n }\n function De() {\n {\n if (y--, y === 0) {\n var e = {\n configurable: !0,\n enumerable: !0,\n writable: !0\n };\n Object.defineProperties(console, {\n log: g({}, e, {\n value: K\n }),\n info: g({}, e, {\n value: H\n }),\n warn: g({}, e, {\n value: X\n }),\n error: g({}, e, {\n value: Z\n }),\n group: g({}, e, {\n value: Q\n }),\n groupCollapsed: g({}, e, {\n value: ee\n }),\n groupEnd: g({}, e, {\n value: re\n })\n });\n }\n y < 0 && l(\"disabledDepth fell below zero. This is a bug in React. Please file an issue.\");\n }\n }\n var A = b.ReactCurrentDispatcher, I;\n function P(e, r, t) {\n {\n if (I === void 0)\n try {\n throw Error();\n } catch (o) {\n var n = o.stack.trim().match(/\\n( *(at )?)/);\n I = n && n[1] || \"\";\n }\n return `\n` + I + e;\n }\n }\n var W = !1, w;\n {\n var Fe = typeof WeakMap == \"function\" ? WeakMap : Map;\n w = new Fe();\n }\n function ne(e, r) {\n if (!e || W)\n return \"\";\n {\n var t = w.get(e);\n if (t !== void 0)\n return t;\n }\n var n;\n W = !0;\n var o = Error.prepareStackTrace;\n Error.prepareStackTrace = void 0;\n var u;\n u = A.current, A.current = null, ke();\n try {\n if (r) {\n var i = function() {\n throw Error();\n };\n if (Object.defineProperty(i.prototype, \"props\", {\n set: function() {\n throw Error();\n }\n }), typeof Reflect == \"object\" && Reflect.construct) {\n try {\n Reflect.construct(i, []);\n } catch (p) {\n n = p;\n }\n Reflect.construct(e, [], i);\n } else {\n try {\n i.call();\n } catch (p) {\n n = p;\n }\n e.call(i.prototype);\n }\n } else {\n try {\n throw Error();\n } catch (p) {\n n = p;\n }\n e();\n }\n } catch (p) {\n if (p && n && typeof p.stack == \"string\") {\n for (var a = p.stack.split(`\n`), c = n.stack.split(`\n`), s = a.length - 1, f = c.length - 1; s >= 1 && f >= 0 && a[s] !== c[f]; )\n f--;\n for (; s >= 1 && f >= 0; s--, f--)\n if (a[s] !== c[f]) {\n if (s !== 1 || f !== 1)\n do\n if (s--, f--, f < 0 || a[s] !== c[f]) {\n var v = `\n` + a[s].replace(\" at new \", \" at \");\n return e.displayName && v.includes(\"<anonymous>\") && (v = v.replace(\"<anonymous>\", e.displayName)), typeof e == \"function\" && w.set(e, v), v;\n }\n while (s >= 1 && f >= 0);\n break;\n }\n }\n } finally {\n W = !1, A.current = u, De(), Error.prepareStackTrace = o;\n }\n var E = e ? e.displayName || e.name : \"\", be = E ? P(E) : \"\";\n return typeof e == \"function\" && w.set(e, be), be;\n }\n function Ae(e, r, t) {\n return ne(e, !1);\n }\n function Ie(e) {\n var r = e.prototype;\n return !!(r && r.isReactComponent);\n }\n function O(e, r, t) {\n if (e == null)\n return \"\";\n if (typeof e == \"function\")\n return ne(e, Ie(e));\n if (typeof e == \"string\")\n return P(e);\n switch (e) {\n case k:\n return P(\"Suspense\");\n case D:\n return P(\"SuspenseList\");\n }\n if (typeof e == \"object\")\n switch (e.$$typeof) {\n case T:\n return Ae(e.render);\n case C:\n return O(e.type, r, t);\n case F: {\n var n = e, o = n._payload, u = n._init;\n try {\n return O(u(o), r, t);\n } catch {\n }\n }\n }\n return \"\";\n }\n var S = Object.prototype.hasOwnProperty, ae = {}, ie = b.ReactDebugCurrentFrame;\n function j(e) {\n if (e) {\n var r = e._owner, t = O(e.type, e._source, r ? r.type : null);\n ie.setExtraStackFrame(t);\n } else\n ie.setExtraStackFrame(null);\n }\n function We(e, r, t, n, o) {\n {\n var u = Function.call.bind(S);\n for (var i in e)\n if (u(e, i)) {\n var a = void 0;\n try {\n if (typeof e[i] != \"function\") {\n var c = Error((n || \"React class\") + \": \" + t + \" type `\" + i + \"` is invalid; it must be a function, usually from the `prop-types` package, but received `\" + typeof e[i] + \"`.This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.\");\n throw c.name = \"Invariant Violation\", c;\n }\n a = e[i](r, i, n, t, null, \"SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED\");\n } catch (s) {\n a = s;\n }\n a && !(a instanceof Error) && (j(o), l(\"%s: type specification of %s `%s` is invalid; the type checker function must return `null` or an `Error` but returned a %s. You may have forgotten to pass an argument to the type checker creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and shape all require an argument).\", n || \"React class\", t, i, typeof a), j(null)), a instanceof Error && !(a.message in ae) && (ae[a.message] = !0, j(o), l(\"Failed %s type: %s\", t, a.message), j(null));\n }\n }\n }\n var $e = Array.isArray;\n function $(e) {\n return $e(e);\n }\n function Ye(e) {\n {\n var r = typeof Symbol == \"function\" && Symbol.toStringTag, t = r && e[Symbol.toStringTag] || e.constructor.name || \"Object\";\n return t;\n }\n }\n function Me(e) {\n try {\n return oe(e), !1;\n } catch {\n return !0;\n }\n }\n function oe(e) {\n return \"\" + e;\n }\n function ue(e) {\n if (Me(e))\n return l(\"The provided key is an unsupported type %s. This value must be coerced to a string before before using it here.\", Ye(e)), oe(e);\n }\n var m = b.ReactCurrentOwner, Ve = {\n key: !0,\n ref: !0,\n __self: !0,\n __source: !0\n }, se, fe, Y;\n Y = {};\n function Le(e) {\n if (S.call(e, \"ref\")) {\n var r = Object.getOwnPropertyDescriptor(e, \"ref\").get;\n if (r && r.isReactWarning)\n return !1;\n }\n return e.ref !== void 0;\n }\n function Ue(e) {\n if (S.call(e, \"key\")) {\n var r = Object.getOwnPropertyDescriptor(e, \"key\").get;\n if (r && r.isReactWarning)\n return !1;\n }\n return e.key !== void 0;\n }\n function Ne(e, r) {\n if (typeof e.ref == \"string\" && m.current && r && m.current.stateNode !== r) {\n var t = d(m.current.type);\n Y[t] || (l('Component \"%s\" contains the string ref \"%s\". Support for string refs will be removed in a future major release. This case cannot be automatically converted to an arrow function. We ask you to manually fix this case by using useRef() or createRef() instead. Learn more about using refs safely here: https://reactjs.org/link/strict-mode-string-ref', d(m.current.type), e.ref), Y[t] = !0);\n }\n }\n function Be(e, r) {\n {\n var t = function() {\n se || (se = !0, l(\"%s: `key` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://reactjs.org/link/special-props)\", r));\n };\n t.isReactWarning = !0, Object.defineProperty(e, \"key\", {\n get: t,\n configurable: !0\n });\n }\n }\n function qe(e, r) {\n {\n var t = function() {\n fe || (fe = !0, l(\"%s: `ref` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://reactjs.org/link/special-props)\", r));\n };\n t.isReactWarning = !0, Object.defineProperty(e, \"ref\", {\n get: t,\n configurable: !0\n });\n }\n }\n var Ge = function(e, r, t, n, o, u, i) {\n var a = {\n // This tag allows us to uniquely identify this as a React Element\n $$typeof: x,\n // Built-in properties that belong on the element\n type: e,\n key: r,\n ref: t,\n props: i,\n // Record the component responsible for creating this element.\n _owner: u\n };\n return a._store = {}, Object.defineProperty(a._store, \"validated\", {\n configurable: !1,\n enumerable: !1,\n writable: !0,\n value: !1\n }), Object.defineProperty(a, \"_self\", {\n configurable: !1,\n enumerable: !1,\n writable: !1,\n value: n\n }), Object.defineProperty(a, \"_source\", {\n configurable: !1,\n enumerable: !1,\n writable: !1,\n value: o\n }), Object.freeze && (Object.freeze(a.props), Object.freeze(a)), a;\n };\n function ze(e, r, t, n, o) {\n {\n var u, i = {}, a = null, c = null;\n t !== void 0 && (ue(t), a = \"\" + t), Ue(r) && (ue(r.key), a = \"\" + r.key), Le(r) && (c = r.ref, Ne(r, o));\n for (u in r)\n S.call(r, u) && !Ve.hasOwnProperty(u) && (i[u] = r[u]);\n if (e && e.defaultProps) {\n var s = e.defaultProps;\n for (u in s)\n i[u] === void 0 && (i[u] = s[u]);\n }\n if (a || c) {\n var f = typeof e == \"function\" ? e.displayName || e.name || \"Unknown\" : e;\n a && Be(i, f), c && qe(i, f);\n }\n return Ge(e, a, c, o, n, m.current, i);\n }\n }\n var M = b.ReactCurrentOwner, le = b.ReactDebugCurrentFrame;\n function h(e) {\n if (e) {\n var r = e._owner, t = O(e.type, e._source, r ? r.type : null);\n le.setExtraStackFrame(t);\n } else\n le.setExtraStackFrame(null);\n }\n var V;\n V = !1;\n function L(e) {\n return typeof e == \"object\" && e !== null && e.$$typeof === x;\n }\n function ce() {\n {\n if (M.current) {\n var e = d(M.current.type);\n if (e)\n return `\n\nCheck the render method of \\`` + e + \"`.\";\n }\n return \"\";\n }\n }\n function Je(e) {\n {\n if (e !== void 0) {\n var r = e.fileName.replace(/^.*[\\\\\\/]/, \"\"), t = e.lineNumber;\n return `\n\nCheck your code at ` + r + \":\" + t + \".\";\n }\n return \"\";\n }\n }\n var ve = {};\n function Ke(e) {\n {\n var r = ce();\n if (!r) {\n var t = typeof e == \"string\" ? e : e.displayName || e.name;\n t && (r = `\n\nCheck the top-level render call using <` + t + \">.\");\n }\n return r;\n }\n }\n function de(e, r) {\n {\n if (!e._store || e._store.validated || e.key != null)\n return;\n e._store.validated = !0;\n var t = Ke(r);\n if (ve[t])\n return;\n ve[t] = !0;\n var n = \"\";\n e && e._owner && e._owner !== M.current && (n = \" It was passed a child from \" + d(e._owner.type) + \".\"), h(e), l('Each child in a list should have a unique \"key\" prop.%s%s See https://reactjs.org/link/warning-keys for more information.', t, n), h(null);\n }\n }\n function pe(e, r) {\n {\n if (typeof e != \"object\")\n return;\n if ($(e))\n for (var t = 0; t < e.length; t++) {\n var n = e[t];\n L(n) && de(n, r);\n }\n else if (L(e))\n e._store && (e._store.validated = !0);\n else if (e) {\n var o = _e(e);\n if (typeof o == \"function\" && o !== e.entries)\n for (var u = o.call(e), i; !(i = u.next()).done; )\n L(i.value) && de(i.value, r);\n }\n }\n }\n function He(e) {\n {\n var r = e.type;\n if (r == null || typeof r == \"string\")\n return;\n var t;\n if (typeof r == \"function\")\n t = r.propTypes;\n else if (typeof r == \"object\" && (r.$$typeof === T || // Note: Memo only checks outer props here.\n // Inner props are checked in the reconciler.\n r.$$typeof === C))\n t = r.propTypes;\n else\n return;\n if (t) {\n var n = d(r);\n We(t, e.props, \"prop\", n, e);\n } else if (r.PropTypes !== void 0 && !V) {\n V = !0;\n var o = d(r);\n l(\"Component %s declared `PropTypes` instead of `propTypes`. Did you misspell the property assignment?\", o || \"Unknown\");\n }\n typeof r.getDefaultProps == \"function\" && !r.getDefaultProps.isReactClassApproved && l(\"getDefaultProps is only used on classic React.createClass definitions. Use a static property named `defaultProps` instead.\");\n }\n }\n function Xe(e) {\n {\n for (var r = Object.keys(e.props), t = 0; t < r.length; t++) {\n var n = r[t];\n if (n !== \"children\" && n !== \"key\") {\n h(e), l(\"Invalid prop `%s` supplied to `React.Fragment`. React.Fragment can only have `key` and `children` props.\", n), h(null);\n break;\n }\n }\n e.ref !== null && (h(e), l(\"Invalid attribute `ref` supplied to `React.Fragment`.\"), h(null));\n }\n }\n function ge(e, r, t, n, o, u) {\n {\n var i = je(e);\n if (!i) {\n var a = \"\";\n (e === void 0 || typeof e == \"object\" && e !== null && Object.keys(e).length === 0) && (a += \" You likely forgot to export your component from the file it's defined in, or you might have mixed up default and named imports.\");\n var c = Je(o);\n c ? a += c : a += ce();\n var s;\n e === null ? s = \"null\" : $(e) ? s = \"array\" : e !== void 0 && e.$$typeof === x ? (s = \"<\" + (d(e.type) || \"Unknown\") + \" />\", a = \" Did you accidentally export a JSX literal instead of a component?\") : s = typeof e, l(\"React.jsx: type is invalid -- expected a string (for built-in components) or a class/function (for composite components) but got: %s.%s\", s, a);\n }\n var f = ze(e, r, t, o, u);\n if (f == null)\n return f;\n if (i) {\n var v = r.children;\n if (v !== void 0)\n if (n)\n if ($(v)) {\n for (var E = 0; E < v.length; E++)\n pe(v[E], e);\n Object.freeze && Object.freeze(v);\n } else\n l(\"React.jsx: Static children should always be an array. You are likely explicitly calling React.jsxs or React.jsxDEV. Use the Babel transform instead.\");\n else\n pe(v, e);\n }\n return e === _ ? Xe(f) : He(f), f;\n }\n }\n function Ze(e, r, t) {\n return ge(e, r, t, !0);\n }\n function Qe(e, r, t) {\n return ge(e, r, t, !1);\n }\n var er = Qe, rr = Ze;\n R.Fragment = _, R.jsx = er, R.jsxs = rr;\n }(), R);\n}\nexport {\n ir as __require\n};\n//# sourceMappingURL=annotorious-react.es19.js.map\n"],"names":["he","ir","R","Ee","tr","x","ye","_","U","N","B","q","T","k","D","C","F","me","G","Re","_e","b","Te","o","u","i","Ce","Pe","we","Oe","Se","z","je","xe","d","g","y","K","H","X","Z","Q","ke","De","A","I","P","W","w","Fe","p","a","c","s","f","v","E","be","Ae","Ie","O","S","ae","ie","j","We","$e","$","Ye","Me","oe","ue","m","Ve","se","fe","Y","Le","Ue","Ne","Be","qe","Ge","ze","M","h","V","L","ce","ve","Ke","de","pe","He","Xe","ge","Ze","Qe"],"mappings":";;AAEA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AASA,IAAIA;AACJ,SAASC,KAAK;AACZ,SAAOD,KAAKE,KAAKF,KAAK,GAAG,QAAQ,IAAI,aAAa,gBAAgB,WAAW;AAC3E,QAAIG,KAAKC,IAAIC,IAAI,OAAO,IAAI,eAAe,GAAGC,KAAK,OAAO,IAAI,cAAc,GAAGC,IAAI,OAAO,IAAI,gBAAgB,GAAGC,IAAI,OAAO,IAAI,mBAAmB,GAAGC,IAAI,OAAO,IAAI,gBAAgB,GAAGC,IAAI,OAAO,IAAI,gBAAgB,GAAGC,IAAI,OAAO,IAAI,eAAe,GAAGC,IAAI,OAAO,IAAI,mBAAmB,GAAGC,IAAI,OAAO,IAAI,gBAAgB,GAAGC,IAAI,OAAO,IAAI,qBAAqB,GAAGC,IAAI,OAAO,IAAI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E,sJAAsJ;AAAA;AAE1J,cAAAqC,GAAGrC,GAAG,CAAC;AAAA,QACZ;AACD,eAAO,MAAMhD,IAAIuF,GAAGxC,CAAC,IAAIuC,GAAGvC,CAAC,GAAGA;AAAA,MACjC;AAAA,IACF;AACD,aAAS0C,GAAG,GAAG,GAAG,GAAG;AACnB,aAAOD,GAAG,GAAG,GAAG,GAAG,EAAE;AAAA,IACtB;AACD,aAASE,GAAG,GAAG,GAAG,GAAG;AACnB,aAAOF,GAAG,GAAG,GAAG,GAAG,EAAE;AAAA,IACtB;AACD,QAAI,KAAKE,IAAI,KAAKD;AAClB9F,IAAAA,EAAE,WAAWK,GAAGL,EAAE,MAAM,IAAIA,EAAE,OAAO;AAAA,EACzC,EAAK,GAAEA;AACP;"}
1
+ {"version":3,"file":"annotorious-react-manifold.es21.js","sources":["../../annotorious-react/dist/annotorious-react.es21.js"],"sourcesContent":["var r = {};\nexport {\n r as __exports\n};\n//# sourceMappingURL=annotorious-react.es21.js.map\n"],"names":[],"mappings":"AAAG,IAAC,IAAI,CAAA;"}
@@ -1,5 +1,5 @@
1
- var r = {};
1
+ var e = {};
2
2
  export {
3
- r as __exports
3
+ e as __exports
4
4
  };
5
5
  //# sourceMappingURL=annotorious-react-manifold.es22.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"annotorious-react-manifold.es22.js","sources":["../../annotorious-react/dist/annotorious-react.es20.js"],"sourcesContent":["var r = {};\nexport {\n r as __exports\n};\n//# sourceMappingURL=annotorious-react.es20.js.map\n"],"names":[],"mappings":"AAAG,IAAC,IAAI,CAAA;"}
1
+ {"version":3,"file":"annotorious-react-manifold.es22.js","sources":["../../annotorious-react/dist/annotorious-react.es22.js"],"sourcesContent":["var e = {};\nexport {\n e as __exports\n};\n//# sourceMappingURL=annotorious-react.es22.js.map\n"],"names":[],"mappings":"AAAG,IAAC,IAAI,CAAA;"}
@@ -1,7 +1,6 @@
1
1
  import { j as o } from "./annotorious-react-manifold.es7.js";
2
2
  import { useContext as i, useEffect as e } from "react";
3
3
  import { Annotorious as s, useAnnotator as c } from "./annotorious-react-manifold.es8.js";
4
- import "./annotorious-react-manifold.es9.js";
5
4
  import { AnnotoriousManifoldContext as m } from "./annotorious-react-manifold.es5.js";
6
5
  const u = (n) => {
7
6
  const t = c(), { connectAnnotator: r } = i(m);
@@ -9,8 +8,8 @@ const u = (n) => {
9
8
  if (t)
10
9
  return r(n.id, t);
11
10
  }, [t]), /* @__PURE__ */ o.jsx(o.Fragment, { children: n.children });
12
- }, l = (n) => /* @__PURE__ */ o.jsx(s, { children: /* @__PURE__ */ o.jsx(u, { id: n.id, children: n.children }) });
11
+ }, h = (n) => /* @__PURE__ */ o.jsx(s, { children: /* @__PURE__ */ o.jsx(u, { id: n.id, children: n.children }) });
13
12
  export {
14
- l as Annotorious
13
+ h as Annotorious
15
14
  };
16
15
  //# sourceMappingURL=annotorious-react-manifold.es4.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"annotorious-react-manifold.es4.js","sources":["../src/Annotorious.tsx"],"sourcesContent":["import { ReactNode, useContext, useEffect } from 'react';\nimport { Annotation, Annotator, useAnnotator } from '@annotorious/react';\nimport { Annotorious as AnnotoriousInstance } from '@annotorious/react';\nimport { AnnotoriousManifoldContext } from './AnnotoriousManifold';\n\ninterface AnnotoriousProps {\n\n children: ReactNode;\n\n id: string;\n\n}\n\n/**\n * Consumes the standard Annotorious context, and passes the Annotator\n * upwards to the manifold.\n */\nconst AnnotoriousInstanceShim = <I extends Annotation = Annotation, E extends { id: string } = Annotation>(props: AnnotoriousProps) => {\n\n const anno = useAnnotator<Annotator<I, E>>();\n\n const { connectAnnotator } = useContext(AnnotoriousManifoldContext);\n\n useEffect(() => { \n if (anno) {\n return connectAnnotator(props.id, anno);\n }\n }, [anno]);\n\n return <>{props.children}</>;\n\n}\n\n/**\n * An alternative <Annotorious /> component that mimicks the original\n * from @annotorious/react, but injects the shim component, which connects\n * the Annotator to the Manifold.\n */\nexport const Annotorious = (props: AnnotoriousProps) => {\n\n return (\n <AnnotoriousInstance>\n <AnnotoriousInstanceShim id={props.id}>\n {props.children}\n </AnnotoriousInstanceShim>\n </AnnotoriousInstance>\n )\n\n}"],"names":["AnnotoriousInstanceShim","props","anno","useAnnotator","connectAnnotator","useContext","AnnotoriousManifoldContext","useEffect","jsx","Fragment","Annotorious","AnnotoriousInstance"],"mappings":";;;;;AAiBA,MAAMA,IAA0B,CAA2EC,MAA4B;AAErI,QAAMC,IAAOC,KAEP,EAAE,kBAAAC,EAAA,IAAqBC,EAAWC,CAA0B;AAElE,SAAAC,EAAU,MAAM;AACd,QAAIL;AACK,aAAAE,EAAiBH,EAAM,IAAIC,CAAI;AAAA,EACxC,GACC,CAACA,CAAI,CAAC,GAEFM,gBAAAA,EAAAA,IAAAC,EAAAA,UAAA,EAAG,YAAM,SAAS,CAAA;AAE3B,GAOaC,IAAc,CAACT,MAGxBO,gBAAAA,EAAAA,IAACG,KACC,UAACH,gBAAAA,EAAA,IAAAR,GAAA,EAAwB,IAAIC,EAAM,IAChC,UAAMA,EAAA,SACT,CAAA,EACF,CAAA;"}
1
+ {"version":3,"file":"annotorious-react-manifold.es4.js","sources":["../src/Annotorious.tsx"],"sourcesContent":["import { ReactNode, useContext, useEffect } from 'react';\nimport { Annotation, Annotator, useAnnotator } from '@annotorious/react';\nimport { Annotorious as AnnotoriousInstance } from '@annotorious/react';\nimport { AnnotoriousManifoldContext } from './AnnotoriousManifold';\n\ninterface AnnotoriousProps {\n\n children: ReactNode;\n\n id: string;\n\n}\n\n/**\n * Consumes the standard Annotorious context, and passes the Annotator\n * upwards to the manifold.\n */\nconst AnnotoriousInstanceShim = <I extends Annotation = Annotation, E extends { id: string } = Annotation>(props: AnnotoriousProps) => {\n\n const anno = useAnnotator<Annotator<I, E>>();\n\n const { connectAnnotator } = useContext(AnnotoriousManifoldContext);\n\n useEffect(() => { \n if (anno) {\n return connectAnnotator(props.id, anno);\n }\n }, [anno]);\n\n return <>{props.children}</>;\n\n}\n\n/**\n * An alternative <Annotorious /> component that mimicks the original\n * from @annotorious/react, but injects the shim component, which connects\n * the Annotator to the Manifold.\n */\nexport const Annotorious = (props: AnnotoriousProps) => {\n\n return (\n <AnnotoriousInstance>\n <AnnotoriousInstanceShim id={props.id}>\n {props.children}\n </AnnotoriousInstanceShim>\n </AnnotoriousInstance>\n )\n\n}"],"names":["AnnotoriousInstanceShim","props","anno","useAnnotator","connectAnnotator","useContext","AnnotoriousManifoldContext","useEffect","jsx","Fragment","Annotorious","AnnotoriousInstance"],"mappings":";;;;AAiBA,MAAMA,IAA0B,CAA2EC,MAA4B;AAErI,QAAMC,IAAOC,KAEP,EAAE,kBAAAC,EAAA,IAAqBC,EAAWC,CAA0B;AAElE,SAAAC,EAAU,MAAM;AACd,QAAIL;AACK,aAAAE,EAAiBH,EAAM,IAAIC,CAAI;AAAA,EACxC,GACC,CAACA,CAAI,CAAC,GAEFM,gBAAAA,EAAAA,IAAAC,EAAAA,UAAA,EAAG,YAAM,SAAS,CAAA;AAE3B,GAOaC,IAAc,CAACT,MAGxBO,gBAAAA,EAAAA,IAACG,KACC,UAACH,gBAAAA,EAAA,IAAAR,GAAA,EAAwB,IAAIC,EAAM,IAChC,UAAMA,EAAA,SACT,CAAA,EACF,CAAA;"}
@@ -1,6 +1,5 @@
1
- import { Origin as c } from "./annotorious-react-manifold.es10.js";
2
- import "./annotorious-react-manifold.es9.js";
3
- const C = (r) => {
1
+ import { Origin as c } from "./annotorious-react-manifold.es9.js";
2
+ const B = (r) => {
4
3
  const e = (t) => Array.from(r.entries()).reduce((o, [n, s]) => {
5
4
  if (o)
6
5
  return o;
@@ -48,6 +47,6 @@ const C = (r) => {
48
47
  };
49
48
  };
50
49
  export {
51
- C as createManifoldInstance
50
+ B as createManifoldInstance
52
51
  };
53
52
  //# sourceMappingURL=annotorious-react-manifold.es6.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"annotorious-react-manifold.es6.js","sources":["../src/AnnotoriousManifoldInstance.ts"],"sourcesContent":["import { Origin } from '@annotorious/react';\nimport type {\n Annotation, \n AnnotationBody, \n Annotator\n} from '@annotorious/react';\n\nexport interface AnnotoriousManifoldInstance<I extends Annotation = Annotation, E extends { id: string } = Annotation> {\n\n annotators: Annotator<I, E>[];\n\n sources: string[];\n\n addBody(body: AnnotationBody, origin?: Origin): void;\n\n clear(origin: Origin): void;\n\n deleteAnnotation(id: string, origin?: Origin): I | undefined;\n\n deleteBody(body: AnnotationBody, origin?: Origin): void;\n\n destroy(): void;\n\n findAnnotator(annotationId: string): Annotator<I, E> | undefined;\n\n findSource(annotationId: string): string | undefined;\n\n getAnnotation(id: string): I | undefined;\n \n getAnnotations(): I[];\n\n getAnnotator(id: string): Annotator<I, E> | undefined;\n \n setSelected(annotationId: string): void;\n\n updateAnnotation(arg1: string | I, arg2?: I | Origin, arg3?: Origin): void;\n\n}\n\nexport const createManifoldInstance = <I extends Annotation = Annotation, E extends { id: string } = Annotation>(\n annotators: Map<string, Annotator<I, E>>\n): AnnotoriousManifoldInstance<I, E> => {\n\n const find = (annotationId: string): { annotation?: I, source?: string, annotator?: Annotator<I, E> } =>\n Array.from(annotators.entries()).reduce((found, [source, annotator]) => {\n if (found)\n return found;\n\n const annotation = annotator.state.store.getAnnotation(annotationId);\n if (annotation) \n return { annotation, annotator, source };\n }, undefined as { annotation: I, annotator: Annotator<I, E> } | undefined ) || \n\n { annotation: undefined, annotator: undefined, source: undefined };\n\n /*********/\n /** API **/\n /*********/\n\n const addBody = (body: AnnotationBody, origin = Origin.LOCAL) => {\n const { annotator } = find(body.annotation);\n if (annotator)\n annotator.state.store.addBody(body, origin);\n }\n\n const clear = (origin = Origin.LOCAL) =>\n Array.from(annotators.values()).forEach(a => a.state.store.clear(origin));\n\n const deleteAnnotation = (id: string, origin = Origin.LOCAL) => {\n const { annotation, annotator } = find(id);\n\n if (annotator) {\n annotator.state.store.deleteAnnotation(id, origin);\n return annotation;\n }\n }\n\n const deleteBody = (body: AnnotationBody, origin = Origin.LOCAL) => {\n const { annotator } = find(body.annotation);\n if (annotator)\n annotator.state.store.deleteBody(body, origin);\n }\n\n const destroy = () =>\n Array.from(annotators.values()).forEach(a => a.destroy());\n\n const findAnnotator = (annotationId: string) => {\n const { annotator } = find(annotationId);\n return annotator;\n }\n\n const findSource = (annotationId: string) => {\n const { source } = find(annotationId);\n return source;\n }\n\n const getAnnotation = (annotationId: string) => \n find(annotationId).annotation;\n\n const getAnnotations = () => \n Array.from(annotators.values()).reduce((all, annotator) =>\n [...all, ...annotator.state.store.all()], [] as I[]);\n\n const getAnnotator = (id: string) => annotators.get(id);\n\n const updateAnnotation = (arg1: string | I, arg2?: I | Origin, arg3?: Origin) => {\n const oldId: string = typeof arg1 === 'string' ? arg1 : arg1.id;\n\n const { annotator } = find(oldId);\n if (annotator)\n annotator.state.store.updateAnnotation(arg1, arg2, arg3);\n }\n\n const setSelected = (id: string) => {\n const { annotator } = find(id);\n if (annotator)\n annotator.setSelected(id);\n }\n\n return {\n annotators: [...annotators.values()],\n sources: [...annotators.keys()],\n addBody,\n clear,\n deleteAnnotation,\n deleteBody,\n destroy,\n findAnnotator,\n findSource,\n getAnnotation,\n getAnnotations,\n getAnnotator,\n setSelected,\n updateAnnotation\n }\n\n}"],"names":["createManifoldInstance","annotators","find","annotationId","found","source","annotator","annotation","addBody","body","origin","Origin","clear","a","deleteAnnotation","id","deleteBody","destroy","findAnnotator","findSource","getAnnotation","getAnnotations","all","getAnnotator","updateAnnotation","arg1","arg2","arg3","oldId","setSelected"],"mappings":";;AAuCa,MAAAA,IAAyB,CACpCC,MACsC;AAEtC,QAAMC,IAAO,CAACC,MACZ,MAAM,KAAKF,EAAW,SAAS,EAAE,OAAO,CAACG,GAAO,CAACC,GAAQC,CAAS,MAAM;AAClE,QAAAF;AACK,aAAAA;AAET,UAAMG,IAAaD,EAAU,MAAM,MAAM,cAAcH,CAAY;AAC/D,QAAAI;AACK,aAAA,EAAE,YAAAA,GAAY,WAAAD,GAAW,QAAAD;EACpC,GAAG,M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AU,MAAM,MAAM,IAAI,CAAC,GAAG,CAAA,CAAS,GAEjDiB,IAAe,CAACR,MAAed,EAAW,IAAIc,CAAE,GAEhDS,IAAmB,CAACC,GAAkBC,GAAmBC,MAAkB;AAC/E,UAAMC,IAAgB,OAAOH,KAAS,WAAWA,IAAOA,EAAK,IAEvD,EAAE,WAAAnB,EAAA,IAAcJ,EAAK0B,CAAK;AAC5B,IAAAtB,KACFA,EAAU,MAAM,MAAM,iBAAiBmB,GAAMC,GAAMC,CAAI;AAAA,EAAA,GAGrDE,IAAc,CAACd,MAAe;AAClC,UAAM,EAAE,WAAAT,EAAA,IAAcJ,EAAKa,CAAE;AACzB,IAAAT,KACFA,EAAU,YAAYS,CAAE;AAAA,EAAA;AAGrB,SAAA;AAAA,IACL,YAAY,CAAC,GAAGd,EAAW,QAAQ;AAAA,IACnC,SAAS,CAAC,GAAGA,EAAW,MAAM;AAAA,IAC9B,SAAAO;AAAA,IACA,OAAAI;AAAA,IACA,kBAAAE;AAAA,IACA,YAAAE;AAAA,IACA,SAAAC;AAAA,IACA,eAAAC;AAAA,IACA,YAAAC;AAAA,IACA,eAAAC;AAAA,IACA,gBAAAC;AAAA,IACA,cAAAE;AAAA,IACA,aAAAM;AAAA,IACA,kBAAAL;AAAA,EAAA;AAGJ;"}
1
+ {"version":3,"file":"annotorious-react-manifold.es6.js","sources":["../src/AnnotoriousManifoldInstance.ts"],"sourcesContent":["import { Origin } from '@annotorious/react';\nimport type {\n Annotation, \n AnnotationBody, \n Annotator\n} from '@annotorious/react';\n\nexport interface AnnotoriousManifoldInstance<I extends Annotation = Annotation, E extends { id: string } = Annotation> {\n\n annotators: Annotator<I, E>[];\n\n sources: string[];\n\n addBody(body: AnnotationBody, origin?: Origin): void;\n\n clear(origin: Origin): void;\n\n deleteAnnotation(id: string, origin?: Origin): I | undefined;\n\n deleteBody(body: AnnotationBody, origin?: Origin): void;\n\n destroy(): void;\n\n findAnnotator(annotationId: string): Annotator<I, E> | undefined;\n\n findSource(annotationId: string): string | undefined;\n\n getAnnotation(id: string): I | undefined;\n \n getAnnotations(): I[];\n\n getAnnotator(id: string): Annotator<I, E> | undefined;\n \n setSelected(annotationId: string): void;\n\n updateAnnotation(arg1: string | I, arg2?: I | Origin, arg3?: Origin): void;\n\n}\n\nexport const createManifoldInstance = <I extends Annotation = Annotation, E extends { id: string } = Annotation>(\n annotators: Map<string, Annotator<I, E>>\n): AnnotoriousManifoldInstance<I, E> => {\n\n const find = (annotationId: string): { annotation?: I, source?: string, annotator?: Annotator<I, E> } =>\n Array.from(annotators.entries()).reduce((found, [source, annotator]) => {\n if (found)\n return found;\n\n const annotation = annotator.state.store.getAnnotation(annotationId);\n if (annotation) \n return { annotation, annotator, source };\n }, undefined as { annotation: I, annotator: Annotator<I, E> } | undefined ) || \n\n { annotation: undefined, annotator: undefined, source: undefined };\n\n /*********/\n /** API **/\n /*********/\n\n const addBody = (body: AnnotationBody, origin = Origin.LOCAL) => {\n const { annotator } = find(body.annotation);\n if (annotator)\n annotator.state.store.addBody(body, origin);\n }\n\n const clear = (origin = Origin.LOCAL) =>\n Array.from(annotators.values()).forEach(a => a.state.store.clear(origin));\n\n const deleteAnnotation = (id: string, origin = Origin.LOCAL) => {\n const { annotation, annotator } = find(id);\n\n if (annotator) {\n annotator.state.store.deleteAnnotation(id, origin);\n return annotation;\n }\n }\n\n const deleteBody = (body: AnnotationBody, origin = Origin.LOCAL) => {\n const { annotator } = find(body.annotation);\n if (annotator)\n annotator.state.store.deleteBody(body, origin);\n }\n\n const destroy = () =>\n Array.from(annotators.values()).forEach(a => a.destroy());\n\n const findAnnotator = (annotationId: string) => {\n const { annotator } = find(annotationId);\n return annotator;\n }\n\n const findSource = (annotationId: string) => {\n const { source } = find(annotationId);\n return source;\n }\n\n const getAnnotation = (annotationId: string) => \n find(annotationId).annotation;\n\n const getAnnotations = () => \n Array.from(annotators.values()).reduce((all, annotator) =>\n [...all, ...annotator.state.store.all()], [] as I[]);\n\n const getAnnotator = (id: string) => annotators.get(id);\n\n const updateAnnotation = (arg1: string | I, arg2?: I | Origin, arg3?: Origin) => {\n const oldId: string = typeof arg1 === 'string' ? arg1 : arg1.id;\n\n const { annotator } = find(oldId);\n if (annotator)\n annotator.state.store.updateAnnotation(arg1, arg2, arg3);\n }\n\n const setSelected = (id: string) => {\n const { annotator } = find(id);\n if (annotator)\n annotator.setSelected(id);\n }\n\n return {\n annotators: [...annotators.values()],\n sources: [...annotators.keys()],\n addBody,\n clear,\n deleteAnnotation,\n deleteBody,\n destroy,\n findAnnotator,\n findSource,\n getAnnotation,\n getAnnotations,\n getAnnotator,\n setSelected,\n updateAnnotation\n }\n\n}"],"names":["createManifoldInstance","annotators","find","annotationId","found","source","annotator","annotation","addBody","body","origin","Origin","clear","a","deleteAnnotation","id","deleteBody","destroy","findAnnotator","findSource","getAnnotation","getAnnotations","all","getAnnotator","updateAnnotation","arg1","arg2","arg3","oldId","setSelected"],"mappings":";AAuCa,MAAAA,IAAyB,CACpCC,MACsC;AAEtC,QAAMC,IAAO,CAACC,MACZ,MAAM,KAAKF,EAAW,SAAS,EAAE,OAAO,CAACG,GAAO,CAACC,GAAQC,CAAS,MAAM;AAClE,QAAAF;AACK,aAAAA;AAET,UAAMG,IAAaD,EAAU,MAAM,MAAM,cAAcH,CAAY;AAC/D,QAAAI;AACK,aAAA,EAAE,YAAAA,GAAY,WAAAD,GAAW,QAAAD;EACpC,GAAG,MAAuE,KAE1E,EAAE,YAAY,QAAW,WAAW,QAAW,QAAQ,OAAU,GAM7DG,IAAU,CAACC,GAAsBC,IAASC,EAAO,UAAU;AAC/D,UAAM,EAAE,WAAAL,EAAc,IAAAJ,EAAKO,EAAK,UAAU;AACtC,IAAAH,KACFA,EAAU,MAAM,MAAM,QAAQG,GAAMC,CAAM;AAAA,EAAA,GAGxCE,IAAQ,CAACF,IAASC,EAAO,UAC7B,MAAM,KAAKV,EAAW,OAAA,CAAQ,EAAE,QAAQ,CAAKY,MAAAA,EAAE,MAAM,MAAM,M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AAClC,UAAM,EAAE,WAAAT,EAAA,IAAcJ,EAAKa,CAAE;AACzB,IAAAT,KACFA,EAAU,YAAYS,CAAE;AAAA,EAAA;AAGrB,SAAA;AAAA,IACL,YAAY,CAAC,GAAGd,EAAW,QAAQ;AAAA,IACnC,SAAS,CAAC,GAAGA,EAAW,MAAM;AAAA,IAC9B,SAAAO;AAAA,IACA,OAAAI;AAAA,IACA,kBAAAE;AAAA,IACA,YAAAE;AAAA,IACA,SAAAC;AAAA,IACA,eAAAC;AAAA,IACA,YAAAC;AAAA,IACA,eAAAC;AAAA,IACA,gBAAAC;AAAA,IACA,cAAAE;AAAA,IACA,aAAAM;AAAA,IACA,kBAAAL;AAAA,EAAA;AAGJ;"}
@@ -1,6 +1,6 @@
1
- import { __module as e } from "./annotorious-react-manifold.es13.js";
2
- import { __require as r } from "./annotorious-react-manifold.es14.js";
3
- import { __require as o } from "./annotorious-react-manifold.es15.js";
1
+ import { __module as e } from "./annotorious-react-manifold.es12.js";
2
+ import { __require as r } from "./annotorious-react-manifold.es13.js";
3
+ import { __require as o } from "./annotorious-react-manifold.es14.js";
4
4
  process.env.NODE_ENV === "production" ? e.exports = r() : e.exports = o();
5
5
  var m = e.exports;
6
6
  export {
@@ -1,34 +1,34 @@
1
- import { j as S } from "./annotorious-react-manifold.es18.js";
2
- import { createContext as B, forwardRef as F, useState as r, useImperativeHandle as H, useEffect as I, useContext as P } from "react";
1
+ import { j as S } from "./annotorious-react-manifold.es17.js";
2
+ import { createContext as B, forwardRef as F, useState as i, useImperativeHandle as H, useEffect as I, useContext as P } from "react";
3
3
  const p = B({
4
4
  anno: void 0,
5
5
  setAnno: void 0,
6
6
  annotations: [],
7
7
  selection: { selected: [] }
8
8
  }), $ = F((a, m) => {
9
- const [t, f] = r(null), [A, l] = r([]), [g, d] = r({ selected: [] });
9
+ const [t, f] = i(null), [A, r] = i([]), [g, l] = i({ selected: [] });
10
10
  return H(m, () => t), I(() => {
11
11
  if (t) {
12
12
  const { selection: h, store: e } = t.state;
13
- e.all().length > 0 && l(e.all());
14
- const c = (s) => l(() => e.all());
15
- e.observe(c);
13
+ e.all().length > 0 && r(e.all());
14
+ const d = () => r(() => e.all());
15
+ e.observe(d);
16
16
  let o;
17
- const x = h.subscribe(({ selected: s, pointerEvent: j }) => {
17
+ const x = h.subscribe(({ selected: c, pointerEvent: j }) => {
18
18
  o && e.unobserve(o);
19
- const C = (s || []).map(({ id: n, editable: i }) => ({ annotation: e.getAnnotation(n), editable: i }));
20
- d({ selected: C, pointerEvent: j }), o = (n) => {
21
- const { updated: i } = n.changes;
22
- d(({ selected: E }) => ({
19
+ const C = (c || []).map(({ id: n, editable: s }) => ({ annotation: e.getAnnotation(n), editable: s }));
20
+ l({ selected: C, pointerEvent: j }), o = (n) => {
21
+ const { updated: s } = n.changes;
22
+ l(({ selected: E }) => ({
23
23
  selected: E.map(({ annotation: u, editable: b }) => {
24
- const v = i.find((w) => w.oldValue.id === u.id);
24
+ const v = s.find((w) => w.oldValue.id === u.id);
25
25
  return v ? { annotation: v.newValue, editable: b } : { annotation: u, editable: b };
26
26
  })
27
27
  }));
28
- }, e.observe(o, { annotations: s.map(({ id: n }) => n) });
28
+ }, e.observe(o, { annotations: c.map(({ id: n }) => n) });
29
29
  });
30
30
  return () => {
31
- e.unobserve(c), x();
31
+ e.unobserve(d), x();
32
32
  };
33
33
  }
34
34
  }, [t]), /* @__PURE__ */ S.jsx(p.Provider, { value: {
@@ -1 +1 @@
1
- {"version":3,"file":"annotorious-react-manifold.es8.js","sources":["../../annotorious-react/dist/annotorious-react.es2.js"],"sourcesContent":["import { j as I } from \"./annotorious-react.es12.js\";\nimport { createContext as O, forwardRef as R, useState as f, useImperativeHandle as U, useEffect as h, useContext as c } from \"react\";\nimport { useDebounce as C } from \"./annotorious-react.es13.js\";\nconst o = O({\n anno: void 0,\n setAnno: void 0,\n annotations: [],\n selection: { selected: [] }\n}), B = R((t, s) => {\n const [n, u] = f(null), [p, r] = f([]), [m, l] = f({ selected: [] });\n return U(s, () => n), h(() => {\n if (n) {\n const { selection: A, store: e } = n.state;\n e.all().length > 0 && r(e.all());\n const v = (a) => r(() => e.all());\n e.observe(v);\n let i;\n const b = A.subscribe(({ selected: a, pointerEvent: w }) => {\n i && e.unobserve(i);\n const j = (a || []).map(({ id: d, editable: S }) => ({ annotation: e.getAnnotation(d), editable: S }));\n l({ selected: j, pointerEvent: w }), i = (d) => {\n const { updated: S } = d.changes;\n l(({ selected: D }) => ({\n selected: D.map(({ annotation: V, editable: x }) => {\n const g = S.find((E) => E.oldValue.id === V.id);\n return g ? { annotation: g.newValue, editable: x } : { annotation: V, editable: x };\n })\n }));\n }, e.observe(i, { annotations: a.map(({ id: d }) => d) });\n });\n return () => {\n e.unobserve(v), b();\n };\n }\n }, [n]), /* @__PURE__ */ I.jsx(o.Provider, { value: {\n anno: n,\n setAnno: u,\n annotations: p,\n selection: m\n }, children: t.children });\n}), F = () => {\n const { anno: t } = c(o);\n return t;\n}, G = () => {\n const { anno: t } = c(o);\n return t == null ? void 0 : t.state.store;\n}, H = () => {\n const { annotations: t } = c(o);\n return t;\n}, P = (t) => {\n const { annotations: s } = c(o);\n return C(s, t);\n}, J = (t) => t ? P(t) : H(), K = () => {\n const { selection: t } = c(o);\n return t;\n}, L = () => {\n const { anno: t } = c(o);\n return t == null ? void 0 : t.getUser();\n}, _ = () => {\n const { anno: t } = c(o), [s, n] = f([]);\n return h(() => {\n if (t) {\n const { store: u, viewport: p } = t.state;\n if (!p)\n return;\n let r;\n const m = p.subscribe((l) => {\n r && u.unobserve(r);\n const A = l.map((e) => u.getAnnotation(e));\n n(A), r = (e) => {\n const { updated: v } = e.changes;\n n((i) => i.map((b) => {\n const a = v.find((w) => w.oldValue.id === b.id);\n return a ? a.newValue : b;\n }));\n }, u.observe(r, { annotations: l });\n });\n return () => {\n m();\n };\n }\n }, [t]), s;\n}, k = (t) => {\n const s = _();\n return C(s, t);\n}, M = (t) => t ? k(t) : _();\nexport {\n B as Annotorious,\n o as AnnotoriousContext,\n G as useAnnotationStore,\n J as useAnnotations,\n F as useAnnotator,\n L as useAnnotatorUser,\n K as useSelection,\n M as useViewportState\n};\n//# sourceMappingURL=annotorious-react.es2.js.map\n"],"names":["o","O","B","R","t","s","n","u","f","p","r","m","l","U","h","A","v","a","i","b","w","j","d","S","D","V","x","g","E","I","F","c"],"mappings":";;AAGK,MAACA,IAAIC,EAAE;AAAA,EACV,MAAM;AAAA,EACN,SAAS;AAAA,EACT,aAAa,CAAE;AAAA,EACf,WAAW,EAAE,UAAU,GAAI;AAC7B,CAAC,GAAGC,IAAIC,EAAE,CAACC,GAAGC,MAAM;AAClB,QAAM,CAACC,GAAGC,CAAC,IAAIC,EAAE,IAAI,GAAG,CAACC,GAAGC,CAAC,IAAIF,EAAE,EAAE,GAAG,CAACG,GAAGC,CAAC,IAAIJ,EAAE,EAAE,UAAU,CAAE,EAAA,CAAE;AACnE,SAAOK,EAAER,GAAG,MAAMC,CAAC,GAAGQ,EAAE,MAAM;AAC5B,QAAIR,GAAG;AACL,YAAM,EAAE,WAAWS,GAAG,OAAO,EAAG,IAAGT,EAAE;AACrC,QAAE,IAAK,EAAC,SAAS,KAAKI,EAAE,EAAE,IAAG,CAAE;AAC/B,YAAMM,IAAI,CAACC,MAAMP,EAAE,MAAM,EAAE,IAAG,CAAE;AAChC,QAAE,QAAQM,CAAC;AACX,UAAIE;AACJ,YAAMC,IAAIJ,EAAE,UAAU,CAAC,EAAE,UAAUE,GAAG,cAAcG,QAAQ;AAC1D,QAAAF,KAAK,EAAE,UAAUA,CAAC;AAClB,cAAMG,KAAKJ,KAAK,CAAE,GAAE,IAAI,CAAC,EAAE,IAAIK,GAAG,UAAUC,EAAC,OAAQ,EAAE,YAAY,EAAE,cAAcD,CAAC,GAAG,UAAUC,EAAG,EAAC;AACrG,QAAAX,EAAE,EAAE,UAAUS,GAAG,cAAcD,GAAG,GAAGF,IAAI,CAACI,MAAM;AAC9C,gBAAM,EAAE,SAASC,MAAMD,EAAE;AACzB,UAAAV,EAAE,CAAC,EAAE,UAAUY,SAAS;AAAA,YACtB,UAAUA,EAAE,IAAI,CAAC,EAAE,YAAYC,GAAG,UAAUC,QAAQ;AAClD,oBAAMC,IAAIJ,EAAE,KAAK,CAACK,MAAMA,EAAE,SAAS,OAAOH,EAAE,EAAE;AAC9C,qBAAOE,IAAI,EAAE,YAAYA,EAAE,UAAU,UAAUD,EAAG,IAAG,EAAE,YAAYD,GAAG,UAAUC,EAAC;AAAA,YAC/F,CAAa;AAAA,UACF,EAAC;AAAA,QACH,GAAE,EAAE,QAAQR,GAAG,EAAE,aAAaD,EAAE,IAAI,CAAC,EAAE,IAAIK,EAAG,MAAKA,CAAC,EAAG,CAAA;AAAA,MAChE,CAAO;AACD,aAAO,MAAM;AACX,UAAE,UAAUN,CAAC,GAAGG,EAAC;AAAA,MACzB;AAAA,IACK;AAAA,EACL,GAAK,CAACb,CAAC,CAAC,GAAmBuB,gBAAAA,EAAE,IAAI7B,EAAE,UAAU,EAAE,OAAO;AAAA,IAClD,MAAMM;AAAA,IACN,SAASC;AAAA,IACT,aAAaE;AAAA,IACb,WAAWE;AAAAA,EACZ,GAAE,UAAUP,EAAE,SAAQ,CAAE;AAC3B,CAAC,GAAG0B,IAAI,MAAM;AACZ,QAAM,EAAE,MAAM1B,EAAG,IAAG2B,EAAE/B,CAAC;AACvB,SAAOI;AACT;"}
1
+ {"version":3,"file":"annotorious-react-manifold.es8.js","sources":["../../annotorious-react/dist/annotorious-react.es2.js"],"sourcesContent":["import { j as I } from \"./annotorious-react.es13.js\";\nimport { createContext as O, forwardRef as R, useState as f, useImperativeHandle as U, useEffect as h, useContext as c } from \"react\";\nimport { useDebounce as C } from \"./annotorious-react.es14.js\";\nconst o = O({\n anno: void 0,\n setAnno: void 0,\n annotations: [],\n selection: { selected: [] }\n}), B = R((t, s) => {\n const [n, a] = f(null), [p, r] = f([]), [m, u] = f({ selected: [] });\n return U(s, () => n), h(() => {\n if (n) {\n const { selection: A, store: e } = n.state;\n e.all().length > 0 && r(e.all());\n const v = () => r(() => e.all());\n e.observe(v);\n let i;\n const b = A.subscribe(({ selected: l, pointerEvent: w }) => {\n i && e.unobserve(i);\n const j = (l || []).map(({ id: d, editable: S }) => ({ annotation: e.getAnnotation(d), editable: S }));\n u({ selected: j, pointerEvent: w }), i = (d) => {\n const { updated: S } = d.changes;\n u(({ selected: D }) => ({\n selected: D.map(({ annotation: V, editable: x }) => {\n const g = S.find((E) => E.oldValue.id === V.id);\n return g ? { annotation: g.newValue, editable: x } : { annotation: V, editable: x };\n })\n }));\n }, e.observe(i, { annotations: l.map(({ id: d }) => d) });\n });\n return () => {\n e.unobserve(v), b();\n };\n }\n }, [n]), /* @__PURE__ */ I.jsx(o.Provider, { value: {\n anno: n,\n setAnno: a,\n annotations: p,\n selection: m\n }, children: t.children });\n}), F = () => {\n const { anno: t } = c(o);\n return t;\n}, G = () => {\n const { anno: t } = c(o);\n return t == null ? void 0 : t.state.store;\n}, H = () => {\n const { annotations: t } = c(o);\n return t;\n}, P = (t) => {\n const { annotations: s } = c(o);\n return C(s, t);\n}, J = (t) => t ? P(t) : H(), K = () => {\n const { selection: t } = c(o);\n return t;\n}, L = () => {\n const { anno: t } = c(o);\n return t == null ? void 0 : t.getUser();\n}, _ = () => {\n const { anno: t } = c(o), [s, n] = f([]);\n return h(() => {\n if (t) {\n const { store: a, viewport: p } = t.state;\n if (!p)\n return;\n let r;\n const m = p.subscribe((u) => {\n r && a.unobserve(r);\n const A = u.map((e) => a.getAnnotation(e));\n n(A), r = (e) => {\n const { updated: v } = e.changes;\n n((i) => i.map((b) => {\n const l = v.find((w) => w.oldValue.id === b.id);\n return l ? l.newValue : b;\n }));\n }, a.observe(r, { annotations: u });\n });\n return () => {\n m();\n };\n }\n }, [t]), s;\n}, k = (t) => {\n const s = _();\n return C(s, t);\n}, M = (t) => t ? k(t) : _();\nexport {\n B as Annotorious,\n o as AnnotoriousContext,\n G as useAnnotationStore,\n J as useAnnotations,\n F as useAnnotator,\n L as useAnnotatorUser,\n K as useSelection,\n M as useViewportState\n};\n//# sourceMappingURL=annotorious-react.es2.js.map\n"],"names":["o","O","B","R","t","s","n","a","f","p","m","u","U","h","A","v","i","b","l","w","j","d","S","D","V","x","g","E","I","F","c"],"mappings":";;AAGK,MAACA,IAAIC,EAAE;AAAA,EACV,MAAM;AAAA,EACN,SAAS;AAAA,EACT,aAAa,CAAE;AAAA,EACf,WAAW,EAAE,UAAU,GAAI;AAC7B,CAAC,GAAGC,IAAIC,EAAE,CAACC,GAAGC,MAAM;AAClB,QAAM,CAACC,GAAGC,CAAC,IAAIC,EAAE,IAAI,GAAG,CAACC,GAAG,CAAC,IAAID,EAAE,EAAE,GAAG,CAACE,GAAGC,CAAC,IAAIH,EAAE,EAAE,UAAU,CAAE,EAAA,CAAE;AACnE,SAAOI,EAAEP,GAAG,MAAMC,CAAC,GAAGO,EAAE,MAAM;AAC5B,QAAIP,GAAG;AACL,YAAM,EAAE,WAAWQ,GAAG,OAAO,EAAG,IAAGR,EAAE;AACrC,QAAE,IAAK,EAAC,SAAS,KAAK,EAAE,EAAE,IAAG,CAAE;AAC/B,YAAMS,IAAI,MAAM,EAAE,MAAM,EAAE,IAAK,CAAA;AAC/B,QAAE,QAAQA,CAAC;AACX,UAAIC;AACJ,YAAMC,IAAIH,EAAE,UAAU,CAAC,EAAE,UAAUI,GAAG,cAAcC,QAAQ;AAC1D,QAAAH,KAAK,EAAE,UAAUA,CAAC;AAClB,cAAMI,KAAKF,KAAK,CAAE,GAAE,IAAI,CAAC,EAAE,IAAIG,GAAG,UAAUC,EAAC,OAAQ,EAAE,YAAY,EAAE,cAAcD,CAAC,GAAG,UAAUC,EAAG,EAAC;AACrG,QAAAX,EAAE,EAAE,UAAUS,GAAG,cAAcD,GAAG,GAAGH,IAAI,CAACK,MAAM;AAC9C,gBAAM,EAAE,SAASC,MAAMD,EAAE;AACzB,UAAAV,EAAE,CAAC,EAAE,UAAUY,SAAS;AAAA,YACtB,UA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