From 381c3faa46d19981f2f113c45ec42bdd04ef86a1 Mon Sep 17 00:00:00 2001 From: Antonis Lilis Date: Tue, 27 Oct 2026 14:59:14 +0100 Subject: [PATCH] docs(react-native): Document opening the feedback form over a presented sheet on iOS On iOS, UIKit allows one presentation per view controller, so the default Modal-based feedback form can't open while a native-stack sheet is presented. Document rendering the FeedbackForm component inside a FullWindowOverlay as the supported workaround. Co-Authored-By: Claude Opus 4.8 --- .../common/user-feedback/index.mdx | 46 +++++++++++++++++++ 1 file changed, 46 insertions(+) diff --git a/docs/platforms/react-native/common/user-feedback/index.mdx b/docs/platforms/react-native/common/user-feedback/index.mdx index a7ccd6c7cbf4f..ff6fe7c7d6eae 100644 --- a/docs/platforms/react-native/common/user-feedback/index.mdx +++ b/docs/platforms/react-native/common/user-feedback/index.mdx @@ -93,6 +93,52 @@ Note that when the device is offline, the feedback will be stored locally and se +### Opening the Feedback Form Over a Presented Sheet on iOS + +On iOS, `Sentry.showFeedbackForm()`, shake-to-report, and the auto-injected feedback button present the Feedback Form inside a React Native `Modal`. UIKit only allows one presentation per view controller, so when a native-stack screen is already presented as a sheet (`presentation: "formSheet"` or `"modal"` with `@react-navigation/native-stack`), UIKit refuses the second presentation and the form doesn't appear. Android is unaffected. + +To collect feedback while such a sheet is open, render the [`FeedbackForm`](#feedback-form-component) component yourself and control its visibility. On iOS, wrap it in react-native-screens' `FullWindowOverlay` so it draws above the presented sheet: + +```jsx +import { useState } from "react"; +import { Button, Modal, Platform, StyleSheet, View } from "react-native"; +import { FeedbackForm } from "@sentry/react-native"; +import { FullWindowOverlay } from "react-native-screens"; + +function FeedbackButton() { + const [visible, setVisible] = useState(false); + const close = () => setVisible(false); + + // Pass the same options you'd give `feedbackIntegration(...)` + // (formTitle, namePlaceholder, styles, imagePicker, and so on). + const form = ( + + + + ); + + return ( + <> +