Skip to content

Commit f5ed322

Browse files
Replaced quote type to the Text Quote Selector matching shape
1 parent 8ccace6 commit f5ed322

File tree

1 file changed

+10
-2
lines changed

1 file changed

+10
-2
lines changed

packages/text-annotator/src/model/TextAnnotation.ts

Lines changed: 10 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,15 @@ export interface TextAnnotationTarget extends AnnotationTarget {
1414

1515
export interface TextSelector {
1616

17-
quote: string;
17+
/**
18+
* Matches the `Text Quote Selector` spec from the W3C Annotation Data Model
19+
* @see https://www.w3.org/TR/annotation-model/#text-quote-selector
20+
*/
21+
quote: {
22+
exact: string;
23+
prefix: string;
24+
suffix: string;
25+
}
1826

1927
start: number;
2028

@@ -24,4 +32,4 @@ export interface TextSelector {
2432

2533
offsetReference?: HTMLElement
2634

27-
}
35+
}

0 commit comments

Comments
 (0)