From 789a33bf3e94000b0f6a8cddee75eaeb4b52d121 Mon Sep 17 00:00:00 2001 From: fatadel Date: Thu, 28 May 2026 11:51:26 +0200 Subject: [PATCH] Fix type error for consumers on @types/react v19 React.ReactText was removed from @types/react v19. It was an alias for string | number, so substitute the underlying types directly so the SubMenuProps.title declaration keeps compiling against both v18 and v19. --- src/index.d.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/index.d.ts b/src/index.d.ts index bbfc141..7426ec4 100644 --- a/src/index.d.ts +++ b/src/index.d.ts @@ -48,7 +48,7 @@ declare module "@firefox-devtools/react-contextmenu" { } export interface SubMenuProps { - title: React.ReactElement | React.ReactText, + title: React.ReactElement | string | number, attributes?: React.HTMLAttributes, className?: string, disabled?: boolean,