@@ -58,7 +58,7 @@ export const Annotations = () => {
5858 [ interactiveAnnotations , setInteractiveAnnotations ]
5959 ) ;
6060
61- const annotationPositions = useMemo ( ( ) => {
61+ const renderAnnotations = useMemo ( ( ) => {
6262 // A "hack" to prevent using // eslint-disable-next-line @typescript-eslint/no-unused-vars
6363 // We need to re-compute the annotation positions when the chart width or height changes.
6464 width ;
@@ -90,7 +90,7 @@ export const Annotations = () => {
9090 } ;
9191 } ) ;
9292 } )
93- . filter ( ( d ) : d is AnnotationPosition => d !== null ) ;
93+ . filter ( ( d ) : d is RenderAnnotation => d !== null ) ;
9494 } , [
9595 width ,
9696 height ,
@@ -103,8 +103,8 @@ export const Annotations = () => {
103103
104104 return (
105105 < >
106- { annotationPositions . map ( ( annotationPosition ) => {
107- const { annotation, x, y, color, focused } = annotationPosition ;
106+ { renderAnnotations . map ( ( renderAnnotation ) => {
107+ const { annotation, x, y, color, focused } = renderAnnotation ;
108108
109109 return (
110110 < >
@@ -116,15 +116,15 @@ export const Annotations = () => {
116116 focused = { focused }
117117 onClick = { ( ) => handleAnnotationClick ( annotation ) }
118118 />
119- < AnnotationTooltip annotationPosition = { annotationPosition } />
119+ < AnnotationTooltip renderAnnotation = { renderAnnotation } />
120120 </ >
121121 ) ;
122122 } ) }
123123 </ >
124124 ) ;
125125} ;
126126
127- export type AnnotationPosition = {
127+ export type RenderAnnotation = {
128128 annotation : Annotation ;
129129 x : number ;
130130 y : number ;
0 commit comments