Skip to content

Conversation

@daniel-chou-rainho
Copy link
Contributor

📜 Description

This PR adds a resizeToAvoidBottomInset option to SentryFeedbackOptions to allow developers to control whether the view resizes when the on-screen keyboard appears.

This change is non-breaking as the option defaults to true (the current behavior).

💡 Motivation and Context

The current default behavior for the feedback widget is to resize the view when a text field is focused. This pushes the bottom action buttons ("Send" and "Cancel") up above the keyboard, which can be visually disruptive.

This change introduces an option to disable this resizing, allowing the keyboard to overlay the UI instead.

Click to see UI comparison
Before After
old new

💚 How did you test it?

  1. Manually tested the change in the example app on Android.
  2. Verified that setting resizeToAvoidBottomInset to false in the Sentry options resulted in the keyboard overlaying the UI.
  3. Verified that the default behavior (true) remained unchanged.
  4. Ran the full existing test suite via flutter test to check for any regressions.

📝 Checklist

  • I reviewed submitted code
  • I added tests to verify changes
  • No new PII added or SDK only sends newly added PII if sendDefaultPii is enabled
  • I updated the docs if needed
  • All tests passing
  • No breaking changes

🔮 Next steps

Ready for review.

Copy link
Contributor

@buenaflor buenaflor left a comment

Choose a reason for hiding this comment

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

looks good

I'll let @denrase give the final approval

Copy link
Collaborator

@denrase denrase left a comment

Choose a reason for hiding this comment

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

Looks good. Thanks for the detailed description. I merged in main and think we can merge once CI is happy.

@codecov
Copy link

codecov bot commented Aug 11, 2025

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 89.90%. Comparing base (b3c2fc5) to head (6f717b1).
⚠️ Report is 1 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #3154      +/-   ##
==========================================
+ Coverage   87.79%   89.90%   +2.11%     
==========================================
  Files         291       96     -195     
  Lines        9887     3429    -6458     
==========================================
- Hits         8680     3083    -5597     
+ Misses       1207      346     -861     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@denrase
Copy link
Collaborator

denrase commented Aug 12, 2025

Tests are only failing due to e2e token.

@denrase denrase merged commit e10be73 into getsentry:main Aug 12, 2025
49 of 52 checks passed
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.

3 participants