Skip to content

fix: fixes error screen not being shown bug#63

Merged
pandeymangg merged 1 commit into
mainfrom
fix/error
May 21, 2026
Merged

fix: fixes error screen not being shown bug#63
pandeymangg merged 1 commit into
mainfrom
fix/error

Conversation

@pandeymangg
Copy link
Copy Markdown
Contributor

@pandeymangg pandeymangg commented May 21, 2026

@pandeymangg pandeymangg requested a review from Dhruwang May 21, 2026 07:54
@sonarqubecloud
Copy link
Copy Markdown

@coderabbitai
Copy link
Copy Markdown

coderabbitai Bot commented May 21, 2026

Review Change Stack

Walkthrough

The SurveyWebView component relocates two placeholder callback definitions for response-sending completion and error signaling. Previously, getSetIsResponseSendingFinished was passed as a native-side option to renderHtml. The change removes this from native options and instead defines both getSetIsResponseSendingFinished and getSetIsError as noop functions directly within the HTML script's surveyProps object passed to the embedded Formbricks library.

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Title check ✅ Passed The title 'fix: fixes error screen not being shown bug' directly relates to the main change, which is fixing the error screen display functionality in the SurveyWebView component by properly defining error-handling callbacks.
Description check ✅ Passed The description references a specific Linear issue (ENG-1011) and includes a screenshot showing the error dialog that was not being displayed, which relates to the changeset's purpose of fixing error screen visibility.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

Warning

There were issues while running some tools. Please review the errors and either fix the tool's configuration or disable the tool if it's a critical failure.

🔧 ESLint

If the error stems from missing dependencies, add them to the package.json file. For unrecoverable errors (e.g., due to private dependencies), disable the tool in the CodeRabbit configuration.

ESLint skipped: no ESLint configuration detected in root package.json. To enable, add eslint to devDependencies.


Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

Copy link
Copy Markdown

@coderabbitai coderabbitai Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 1

🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In `@packages/react-native/src/components/survey-web-view.tsx`:
- Around line 371-382: Add a small Vitest unit test that asserts renderHtml(...)
(or the function that returns the WebView HTML used by loadSurvey) includes both
injected callback placeholders for getSetIsResponseSendingFinished and
getSetIsError so they can't be dropped by accident; specifically call renderHtml
or the helper that produces the HTML used by loadSurvey, then assert the
returned string contains the expected identifiers (e.g.,
"getSetIsResponseSendingFinished" and "getSetIsError" or their exact placeholder
signatures) and any surrounding call/assignment pattern your runtime expects,
failing the test if either is missing.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: ASSERTIVE

Plan: Pro

Run ID: d9f4f1ba-db34-4f1b-9614-6e055c06267a

📥 Commits

Reviewing files that changed from the base of the PR and between 5427fdc and 16a5d9a.

📒 Files selected for processing (1)
  • packages/react-native/src/components/survey-web-view.tsx

Comment thread packages/react-native/src/components/survey-web-view.tsx
@pandeymangg pandeymangg added this pull request to the merge queue May 21, 2026
Merged via the queue into main with commit 0876570 May 21, 2026
10 checks passed
@pandeymangg pandeymangg deleted the fix/error branch May 21, 2026 10:38
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants