@recogito/text-annotator 3.0.0-rc.11 → 3.0.0-rc.12

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 (36) hide show
  1. package/dist/src/SelectionHandler.d.ts +1 -2
  2. package/dist/src/TextAnnotatorOptions.d.ts +1 -0
  3. package/dist/src/api/scrollIntoView.d.ts +1 -1
  4. package/dist/src/highlight/HighlightPainter.d.ts +8 -19
  5. package/dist/src/highlight/HighlightStyle.d.ts +9 -0
  6. package/dist/src/highlight/canvas/highlightRenderer.d.ts +11 -0
  7. package/dist/src/highlight/canvas/index.d.ts +1 -0
  8. package/dist/src/highlight/css/highlightRenderer.d.ts +11 -0
  9. package/dist/src/highlight/css/highlights.d.ts +10 -0
  10. package/dist/src/highlight/css/index.d.ts +2 -0
  11. package/dist/src/highlight/index.d.ts +2 -2
  12. package/dist/src/highlight/viewport.d.ts +12 -0
  13. package/dist/src/index.d.ts +1 -0
  14. package/dist/src/model/core/TextAnnotation.d.ts +1 -1
  15. package/dist/src/presence/index.d.ts +1 -1
  16. package/dist/src/presence/presencePainter.d.ts +4 -0
  17. package/dist/src/state/index.d.ts +0 -1
  18. package/dist/src/utils/debounce.d.ts +1 -0
  19. package/dist/src/utils/getAnnotatableFragment.d.ts +5 -0
  20. package/dist/src/utils/index.d.ts +8 -0
  21. package/dist/src/utils/isRevived.d.ts +2 -0
  22. package/dist/src/utils/rangeToSelector.d.ts +2 -0
  23. package/dist/src/utils/reviveAnnotation.d.ts +2 -0
  24. package/dist/src/utils/reviveSelector.d.ts +2 -0
  25. package/dist/src/utils/reviveTarget.d.ts +2 -0
  26. package/dist/src/utils/splitAnnotatableRanges.d.ts +6 -0
  27. package/dist/text-annotator.css +1 -1
  28. package/dist/text-annotator.es.js +1203 -849
  29. package/dist/text-annotator.es.js.map +1 -1
  30. package/dist/text-annotator.umd.js +2 -1
  31. package/dist/text-annotator.umd.js.map +1 -1
  32. package/package.json +7 -6
  33. package/dist/src/highlight/highlightLayer.d.ts +0 -11
  34. package/dist/src/highlight/trackViewport.d.ts +0 -3
  35. package/dist/src/presence/PresencePainter.d.ts +0 -4
  36. package/dist/src/state/reviveTarget.d.ts +0 -9
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@recogito/text-annotator",
3
- "version": "3.0.0-rc.11",
3
+ "version": "3.0.0-rc.12",
4
4
  "description": "A JavaScript text annotation library",
5
5
  "author": "Rainer Simon",
6
6
  "license": "BSD-3-Clause",
@@ -28,16 +28,17 @@
28
28
  "devDependencies": {
29
29
  "@types/jsdom": "^21.1.6",
30
30
  "@types/rbush": "^3.0.3",
31
- "@types/uuid": "^9.0.7",
31
+ "@types/uuid": "^9.0.8",
32
32
  "jsdom": "^23.0.1",
33
- "svelte": "^4.2.8",
33
+ "svelte": "^4.2.11",
34
34
  "typescript": "^5.3.3",
35
- "vite": "^5.0.11",
36
- "vite-plugin-dts": "^3.7.0",
37
- "vitest": "^1.1.3"
35
+ "vite": "^5.1.3",
36
+ "vite-plugin-dts": "^3.7.2",
37
+ "vitest": "^1.3.0"
38
38
  },
39
39
  "dependencies": {
40
40
  "@annotorious/core": "^3.0.0-rc.18",
41
+ "colord": "^2.9.3",
41
42
  "rbush": "^3.0.1",
42
43
  "uuid": "^9.0.1"
43
44
  }
@@ -1,11 +0,0 @@
1
- import type { DrawingStyle, Filter, ViewportState } from '@annotorious/core';
2
- import type { TextAnnotation } from '../model';
3
- import type { TextAnnotatorState } from '../state';
4
- import { type HighlightPainter } from './HighlightPainter';
5
- export declare const createHighlightLayer: (container: HTMLElement, state: TextAnnotatorState, viewport: ViewportState) => {
6
- destroy: () => void;
7
- redraw: () => number;
8
- setDrawingStyle: (style: DrawingStyle | ((a: TextAnnotation, selected?: boolean) => DrawingStyle)) => void;
9
- setFilter: (filter?: Filter) => void;
10
- setPainter: (painter: HighlightPainter) => HighlightPainter;
11
- };
@@ -1,3 +0,0 @@
1
- import type { ViewportState } from '@annotorious/core';
2
- import type { TextAnnotation } from '../model';
3
- export declare const trackViewport: (viewport: ViewportState) => (annotations: TextAnnotation[]) => void;
@@ -1,4 +0,0 @@
1
- import type { PresenceProvider } from '@annotorious/core';
2
- import type { HighlightPainter } from '../highlight';
3
- import type { PresencePainterOptions } from './PresencePainterOptions';
4
- export declare const createPainter: (provider: PresenceProvider, opts?: PresencePainterOptions) => HighlightPainter;
@@ -1,9 +0,0 @@
1
- import type { TextAnnotationTarget } from '../model';
2
- /**
3
- * Recalculates the DOM range from the given text annotation target.
4
- *
5
- * @param annotation the text annotation
6
- * @param container the HTML container of the annotated content
7
- * @returns the DOM range
8
- */
9
- export declare const reviveTarget: (target: TextAnnotationTarget, container: HTMLElement) => TextAnnotationTarget;