@cogic/annotorious 2.7.15 → 2.7.16

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@cogic/annotorious",
3
- "version": "2.7.15",
3
+ "version": "2.7.16",
4
4
  "description": "A JavaScript image annotation library",
5
5
  "main": "dist/annotorious.min.js",
6
6
  "scripts": {
@@ -307,6 +307,8 @@ export default class ImageAnnotator extends Component {
307
307
  getSelectedImageSnippet = () =>
308
308
  this.annotationLayer.getSelectedImageSnippet();
309
309
 
310
+ getCurrentDrawingTool = () => this.annotationLayer.tools?.current;
311
+
310
312
  listDrawingTools = () =>
311
313
  this.annotationLayer.listDrawingTools();
312
314
 
package/src/index.jsx CHANGED
@@ -200,6 +200,8 @@ export class Annotorious {
200
200
  getSelectedImageSnippet = () =>
201
201
  this._app.current.getSelectedImageSnippet();
202
202
 
203
+ getCurrentDrawingTool = () => this._app.current.getCurrentDrawingTool();
204
+
203
205
  listDrawingTools = () =>
204
206
  this._app.current.listDrawingTools();
205
207