From d4f3be276d3e39ce968a0ad1d7a381facc90d2ac Mon Sep 17 00:00:00 2001 From: Ty Rauber Date: Thu, 3 Oct 2024 13:01:06 +0200 Subject: [PATCH] fix: typescript failure --- javascript/components/annotations/Annotation.tsx | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/javascript/components/annotations/Annotation.tsx b/javascript/components/annotations/Annotation.tsx index 448e8d798..68057e56a 100644 --- a/javascript/components/annotations/Annotation.tsx +++ b/javascript/components/annotations/Annotation.tsx @@ -127,7 +127,10 @@ const Annotation = React.forwardRef( const children = []; const symbolStyle: SymbolLayerStyleProps | undefined = props.icon - ? { ...props.style, iconImage: props.icon } + ? { + ...props.style, + iconImage: typeof props.icon === "string" ? props.icon : undefined, + } : undefined; if (symbolStyle) {