From 3d59afde069b64a5978c05c479e42f36fa120f10 Mon Sep 17 00:00:00 2001 From: Bartosz Grajdek Date: Wed, 22 May 2024 10:25:23 +0200 Subject: [PATCH] fix: eslint dependency problem --- src/MarkdownTextInput.web.tsx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/MarkdownTextInput.web.tsx b/src/MarkdownTextInput.web.tsx index e7edead7..f363f9cf 100644 --- a/src/MarkdownTextInput.web.tsx +++ b/src/MarkdownTextInput.web.tsx @@ -300,7 +300,7 @@ const MarkdownTextInput = React.forwardRef( return; } - const isContained = CursorUtils.restrictRanges(divRef.current, value ?? ''); + const isContained = CursorUtils.restrictRanges(divRef.current, (divRef.current as HTMLInputElement)?.value ?? ''); const newSelection = predefinedSelection && isContained ? predefinedSelection : CursorUtils.getCurrentCursorPosition(divRef.current); if (newSelection && (!contentSelection.current || contentSelection.current.start !== newSelection.start || contentSelection.current.end !== newSelection.end)) {