@annotorious/react-manifold 0.2.1 → 0.3.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.
@@ -1,13 +1,17 @@
1
- import { Annotorious as t } from "./annotorious-react-manifold.es2.js";
2
- import { AnnotoriousManifold as r, AnnotoriousManifoldContext as i, useAnnotations as s, useAnnotoriousManifold as a, useSelection as f } from "./annotorious-react-manifold.es3.js";
1
+ import { Annotorious as n } from "./annotorious-react-manifold.es2.js";
2
+ import { AnnotoriousManifold as r, AnnotoriousManifoldContext as i, useAnnotations as s, useAnnotoriousManifold as f, useSelection as a } from "./annotorious-react-manifold.es3.js";
3
3
  import { createManifoldInstance as l } from "./annotorious-react-manifold.es4.js";
4
+ import { OSDViewerContext as d, OSDViewerManifold as A, useViewers as M } from "./annotorious-react-manifold.es5.js";
4
5
  export {
5
- t as Annotorious,
6
+ n as Annotorious,
6
7
  r as AnnotoriousManifold,
7
8
  i as AnnotoriousManifoldContext,
9
+ d as OSDViewerContext,
10
+ A as OSDViewerManifold,
8
11
  l as createManifoldInstance,
9
12
  s as useAnnotations,
10
- a as useAnnotoriousManifold,
11
- f as useSelection
13
+ f as useAnnotoriousManifold,
14
+ a as useSelection,
15
+ M as useViewers
12
16
  };
13
17
  //# sourceMappingURL=annotorious-react-manifold.es.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"annotorious-react-manifold.es.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;"}
1
+ {"version":3,"file":"annotorious-react-manifold.es.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;"}
@@ -1,5 +1,5 @@
1
- var e = {};
1
+ var r = {};
2
2
  export {
3
- e as __exports
3
+ r as __exports
4
4
  };
5
5
  //# sourceMappingURL=annotorious-react-manifold.es10.js.map
@@ -0,0 +1,5 @@
1
+ var e = {};
2
+ export {
3
+ e as __exports
4
+ };
5
+ //# sourceMappingURL=annotorious-react-manifold.es11.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"annotorious-react-manifold.es11.js","sources":[],"sourcesContent":[],"names":[],"mappings":";"}
@@ -1,4 +1,4 @@
1
- import { j as n } from "./annotorious-react-manifold.es5.js";
1
+ import { j as n } from "./annotorious-react-manifold.es6.js";
2
2
  import { useContext as e, useEffect as s } from "react";
3
3
  import { Annotorious as i, useAnnotator as c } from "@annotorious/react";
4
4
  import { AnnotoriousManifoldContext as u } from "./annotorious-react-manifold.es3.js";
@@ -1,4 +1,4 @@
1
- import { j as _ } from "./annotorious-react-manifold.es5.js";
1
+ import { j as _ } from "./annotorious-react-manifold.es6.js";
2
2
  import { createContext as I, useState as A, useRef as O, useEffect as P, useContext as M } from "react";
3
3
  import { createManifoldInstance as k } from "./annotorious-react-manifold.es4.js";
4
4
  const l = I(), D = (n) => {
@@ -1,9 +1,18 @@
1
- import { __module as e } from "./annotorious-react-manifold.es6.js";
2
- import { __require as r } from "./annotorious-react-manifold.es7.js";
3
- import { __require as o } from "./annotorious-react-manifold.es8.js";
4
- process.env.NODE_ENV === "production" ? e.exports = r() : e.exports = o();
5
- var m = e.exports;
1
+ import { j as o } from "./annotorious-react-manifold.es6.js";
2
+ import { createContext as i, useState as n, useContext as w } from "react";
3
+ const r = i({
4
+ viewers: void 0,
5
+ setViewers: void 0
6
+ }), v = (e) => {
7
+ const [t, s] = n(/* @__PURE__ */ new Map());
8
+ return /* @__PURE__ */ o.jsx(r.Provider, { value: { viewers: t, setViewers: s }, children: e.children });
9
+ }, x = () => {
10
+ const { viewers: e } = w(r);
11
+ return e;
12
+ };
6
13
  export {
7
- m as j
14
+ r as OSDViewerContext,
15
+ v as OSDViewerManifold,
16
+ x as useViewers
8
17
  };
9
18
  //# sourceMappingURL=annotorious-react-manifold.es5.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"annotorious-react-manifold.es5.js","sources":["../node_modules/react/jsx-runtime.js"],"sourcesContent":["'use strict';\n\nif (process.env.NODE_ENV === 'production') {\n module.exports = require('./cjs/react-jsx-runtime.production.min.js');\n} else {\n module.exports = require('./cjs/react-jsx-runtime.development.js');\n}\n"],"names":["jsxRuntimeModule","require$$0","require$$1"],"mappings":";;;AAEI,QAAQ,IAAI,aAAa,eAC3BA,EAAA,UAAiBC,MAEjBD,EAAA,UAAiBE;;","x_google_ignoreList":[0]}
1
+ {"version":3,"file":"annotorious-react-manifold.es5.js","sources":["../src/openseadragon/OSDViewerManifold.tsx"],"sourcesContent":["import { ReactNode, createContext, useContext, useState } from 'react';\nimport { Viewer } from '@annotorious/react';\n\ninterface OSDViewerContextValue {\n\n viewers: Map<string, Viewer>;\n\n setViewers: React.Dispatch<React.SetStateAction<Map<string, Viewer>>>\n\n}\n\nexport const OSDViewerContext = createContext<OSDViewerContextValue>({\n\n viewers: undefined,\n\n setViewers: undefined,\n\n});\n\nexport const OSDViewerManifold = (props: { children: ReactNode }) => {\n\n const [viewers, setViewers] = useState(new Map<string, Viewer>());\n\n return (\n <OSDViewerContext.Provider value={{ viewers, setViewers }}>\n {props.children}\n </OSDViewerContext.Provider>\n )\n\n}\n\nexport const useViewers = () => {\n const { viewers } = useContext(OSDViewerContext);\n return viewers;\n}"],"names":["OSDViewerContext","createContext","OSDViewerManifold","props","viewers","setViewers","useState","jsx","useViewers","useContext"],"mappings":";;AAWO,MAAMA,IAAmBC,EAAqC;AAAA,EAEnE,SAAS;AAAA,EAET,YAAY;AAEd,CAAC,GAEYC,IAAoB,CAACC,MAAmC;AAEnE,QAAM,CAACC,GAASC,CAAU,IAAIC,EAAS,oBAAI,KAAqB;AAG9D,SAAAC,gBAAAA,MAACP,EAAiB,UAAjB,EAA0B,OAAO,EAAE,SAAAI,GAAS,YAAAC,EAC1C,GAAA,UAAAF,EAAM,SACT,CAAA;AAGJ,GAEaK,IAAa,MAAM;AAC9B,QAAM,EAAE,SAAAJ,EAAA,IAAYK,EAAWT,CAAgB;AACxC,SAAAI;AACT;"}
@@ -1,5 +1,9 @@
1
- var e = { exports: {} };
1
+ import { __module as e } from "./annotorious-react-manifold.es7.js";
2
+ import { __require as r } from "./annotorious-react-manifold.es8.js";
3
+ import { __require as o } from "./annotorious-react-manifold.es9.js";
4
+ process.env.NODE_ENV === "production" ? e.exports = r() : e.exports = o();
5
+ var m = e.exports;
2
6
  export {
3
- e as __module
7
+ m as j
4
8
  };
5
9
  //# sourceMappingURL=annotorious-react-manifold.es6.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"annotorious-react-manifold.es6.js","sources":[],"sourcesContent":[],"names":[],"mappings":";"}
1
+ {"version":3,"file":"annotorious-react-manifold.es6.js","sources":["../node_modules/react/jsx-runtime.js"],"sourcesContent":["'use strict';\n\nif (process.env.NODE_ENV === 'production') {\n module.exports = require('./cjs/react-jsx-runtime.production.min.js');\n} else {\n module.exports = require('./cjs/react-jsx-runtime.development.js');\n}\n"],"names":["jsxRuntimeModule","require$$0","require$$1"],"mappings":";;;AAEI,QAAQ,IAAI,aAAa,eAC3BA,EAAA,UAAiBC,MAEjBD,EAAA,UAAiBE;;","x_google_ignoreList":[0]}
@@ -1,33 +1,5 @@
1
- import { __exports as t } from "./annotorious-react-manifold.es9.js";
2
- import R from "react";
3
- /**
4
- * @license React
5
- * react-jsx-runtime.production.min.js
6
- *
7
- * Copyright (c) Facebook, Inc. and its affiliates.
8
- *
9
- * This source code is licensed under the MIT license found in the
10
- * LICENSE file in the root directory of this source tree.
11
- */
12
- var p;
13
- function v() {
14
- if (p)
15
- return t;
16
- p = 1;
17
- var s = R, m = Symbol.for("react.element"), l = Symbol.for("react.fragment"), c = Object.prototype.hasOwnProperty, d = s.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner, y = { key: !0, ref: !0, __self: !0, __source: !0 };
18
- function i(o, r, u) {
19
- var e, n = {}, _ = null, f = null;
20
- u !== void 0 && (_ = "" + u), r.key !== void 0 && (_ = "" + r.key), r.ref !== void 0 && (f = r.ref);
21
- for (e in r)
22
- c.call(r, e) && !y.hasOwnProperty(e) && (n[e] = r[e]);
23
- if (o && o.defaultProps)
24
- for (e in r = o.defaultProps, r)
25
- n[e] === void 0 && (n[e] = r[e]);
26
- return { $$typeof: m, type: o, key: _, ref: f, props: n, _owner: d.current };
27
- }
28
- return t.Fragment = l, t.jsx = i, t.jsxs = i, t;
29
- }
1
+ var e = { exports: {} };
30
2
  export {
31
- v as __require
3
+ e as __module
32
4
  };
33
5
  //# sourceMappingURL=annotorious-react-manifold.es7.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"annotorious-react-manifold.es7.js","sources":["../node_modules/react/cjs/react-jsx-runtime.production.min.js"],"sourcesContent":["/**\n * @license React\n * react-jsx-runtime.production.min.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 */\n'use strict';var f=require(\"react\"),k=Symbol.for(\"react.element\"),l=Symbol.for(\"react.fragment\"),m=Object.prototype.hasOwnProperty,n=f.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,p={key:!0,ref:!0,__self:!0,__source:!0};\nfunction q(c,a,g){var b,d={},e=null,h=null;void 0!==g&&(e=\"\"+g);void 0!==a.key&&(e=\"\"+a.key);void 0!==a.ref&&(h=a.ref);for(b in a)m.call(a,b)&&!p.hasOwnProperty(b)&&(d[b]=a[b]);if(c&&c.defaultProps)for(b in a=c.defaultProps,a)void 0===d[b]&&(d[b]=a[b]);return{$$typeof:k,type:c,key:e,ref:h,props:d,_owner:n.current}}exports.Fragment=l;exports.jsx=q;exports.jsxs=q;\n"],"names":["f","require$$0","k","m","n","p","q","c","a","g","b","d","e","h","reactJsxRuntime_production_min"],"mappings":";;;;;;;;;;;;;;;;AASa,MAAIA,IAAEC,GAAiBC,IAAE,OAAO,IAAI,eAAe,GAAE,IAAE,OAAO,IAAI,gBAAgB,GAAEC,IAAE,OAAO,UAAU,gBAAeC,IAAEJ,EAAE,mDAAmD,mBAAkBK,IAAE,EAAC,KAAI,IAAG,KAAI,IAAG,QAAO,IAAG,UAAS,GAAE;AAClP,WAASC,EAAEC,GAAEC,GAAEC,GAAE;AAAC,QAAIC,GAAEC,IAAE,IAAGC,IAAE,MAAKC,IAAE;AAAK,IAASJ,MAAT,WAAaG,IAAE,KAAGH,IAAYD,EAAE,QAAX,WAAiBI,IAAE,KAAGJ,EAAE,MAAcA,EAAE,QAAX,WAAiBK,IAAEL,EAAE;AAAK,SAAIE,KAAKF;AAAE,MAAAL,EAAE,KAAKK,GAAEE,CAAC,KAAG,CAACL,EAAE,eAAeK,CAAC,MAAIC,EAAED,CAAC,IAAEF,EAAEE,CAAC;AAAG,QAAGH,KAAGA,EAAE;AAAa,WAAIG,KAAKF,IAAED,EAAE,cAAaC;AAAE,QAASG,EAAED,CAAC,MAAZ,WAAgBC,EAAED,CAAC,IAAEF,EAAEE,CAAC;AAAG,WAAM,EAAC,UAASR,GAAE,MAAKK,GAAE,KAAIK,GAAE,KAAIC,GAAE,OAAMF,GAAE,QAAOP,EAAE,QAAO;AAAA,EAAC;AAAC,SAAAU,aAAiB,GAAEA,EAAW,MAACR,GAAEQ,EAAA,OAAaR;;","x_google_ignoreList":[0]}
1
+ {"version":3,"file":"annotorious-react-manifold.es7.js","sources":[],"sourcesContent":[],"names":[],"mappings":";"}