diff --git a/src/components/bottomSheet/index.tsx b/src/components/bottomSheet/index.tsx index 081fa5e..6ee9a60 100644 --- a/src/components/bottomSheet/index.tsx +++ b/src/components/bottomSheet/index.tsx @@ -304,14 +304,15 @@ const BottomSheet = forwardRef( /** * Extracts and caches the _nativeTag property of ContentWrapper */ - let extractNativeTag = useCallback( - // @ts-expect-error - ({ target: { _nativeTag: tag = undefined } }: LayoutChangeEvent) => { - if (!cachedContentWrapperNativeTag.current) - cachedContentWrapperNativeTag.current = tag; - }, - [] - ); + let extractNativeTag = useCallback(({ target }: LayoutChangeEvent) => { + const tag = + Platform.OS === 'web' + ? undefined + : // @ts-expect-error + target?._nativeTag; + if (!cachedContentWrapperNativeTag.current) + cachedContentWrapperNativeTag.current = tag; + }, []); /** * Expands the bottom sheet.