-
-
Notifications
You must be signed in to change notification settings - Fork 342
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
(1) feat: Add Feedback Form Component #4328
(1) feat: Add Feedback Form Component #4328
Conversation
Co-authored-by: Krystof Woldrich <[email protected]>
Android (legacy) Performance metrics 🚀
|
Revision | Plain | With Sentry | Diff |
---|---|---|---|
8ae23a7 | 526.83 ms | 513.38 ms | -13.45 ms |
61310e1 | 464.42 ms | 452.47 ms | -11.95 ms |
13f280b | 486.16 ms | 472.45 ms | -13.71 ms |
c6f01ea | 486.20 ms | 486.98 ms | 0.77 ms |
1d86dd6 | 405.14 ms | 411.06 ms | 5.92 ms |
cdf2bdf | 448.42 ms | 443.42 ms | -5.00 ms |
de59d3a | 486.48 ms | 495.66 ms | 9.18 ms |
f06c879 | 408.41 ms | 424.54 ms | 16.13 ms |
d2c32bb | 448.85 ms | 450.19 ms | 1.34 ms |
8ab11b6 | 462.10 ms | 450.40 ms | -11.70 ms |
App size
Revision | Plain | With Sentry | Diff |
---|---|---|---|
8ae23a7 | 17.74 MiB | 20.07 MiB | 2.34 MiB |
61310e1 | 17.74 MiB | 20.08 MiB | 2.35 MiB |
13f280b | 17.74 MiB | 20.08 MiB | 2.34 MiB |
c6f01ea | 17.74 MiB | 20.10 MiB | 2.36 MiB |
1d86dd6 | 17.73 MiB | 19.86 MiB | 2.12 MiB |
cdf2bdf | 17.74 MiB | 20.10 MiB | 2.36 MiB |
de59d3a | 17.74 MiB | 20.10 MiB | 2.36 MiB |
f06c879 | 17.73 MiB | 19.85 MiB | 2.12 MiB |
d2c32bb | 17.74 MiB | 20.08 MiB | 2.34 MiB |
8ab11b6 | 17.74 MiB | 20.09 MiB | 2.35 MiB |
Previous results on branch: antonis/3859-newCaptureFeedbackAPI-Form
Startup times
Revision | Plain | With Sentry | Diff |
---|---|---|---|
41e9784 | 450.17 ms | 448.69 ms | -1.48 ms |
cadf235 | 462.20 ms | 463.34 ms | 1.14 ms |
d33790a | 442.93 ms | 439.94 ms | -3.00 ms |
a06f6ba | 424.02 ms | 415.82 ms | -8.20 ms |
e0624b6 | 447.67 ms | 441.08 ms | -6.59 ms |
a3ba405 | 438.16 ms | 435.78 ms | -2.38 ms |
50c70c0 | 496.82 ms | 526.02 ms | 29.20 ms |
561640f | 461.96 ms | 458.11 ms | -3.85 ms |
0781f75 | 452.32 ms | 457.22 ms | 4.91 ms |
38a278b | 473.58 ms | 468.76 ms | -4.82 ms |
App size
Revision | Plain | With Sentry | Diff |
---|---|---|---|
41e9784 | 17.75 MiB | 20.12 MiB | 2.37 MiB |
cadf235 | 17.74 MiB | 20.09 MiB | 2.35 MiB |
d33790a | 17.74 MiB | 20.10 MiB | 2.36 MiB |
a06f6ba | 17.74 MiB | 20.09 MiB | 2.35 MiB |
e0624b6 | 17.74 MiB | 20.10 MiB | 2.36 MiB |
a3ba405 | 17.74 MiB | 20.09 MiB | 2.35 MiB |
50c70c0 | 17.74 MiB | 20.10 MiB | 2.36 MiB |
561640f | 17.74 MiB | 20.09 MiB | 2.35 MiB |
0781f75 | 17.74 MiB | 20.09 MiB | 2.35 MiB |
38a278b | 17.74 MiB | 20.10 MiB | 2.37 MiB |
Android (new) Performance metrics 🚀
|
Revision | Plain | With Sentry | Diff |
---|---|---|---|
b1e8712+dirty | 322.55 ms | 331.84 ms | 9.29 ms |
07e58c9+dirty | 391.00 ms | 409.66 ms | 18.66 ms |
7bc4d75+dirty | 420.96 ms | 472.25 ms | 51.29 ms |
12427f4+dirty | 379.48 ms | 400.92 ms | 21.44 ms |
9282172+dirty | 363.57 ms | 399.78 ms | 36.20 ms |
43e66e0+dirty | 378.20 ms | 404.59 ms | 26.40 ms |
eb1e19f+dirty | 391.37 ms | 418.27 ms | 26.90 ms |
8e80789+dirty | 464.48 ms | 551.10 ms | 86.63 ms |
cdf2bdf+dirty | 391.69 ms | 461.14 ms | 69.45 ms |
e1ea4a8+dirty | 451.98 ms | 497.58 ms | 45.60 ms |
App size
Revision | Plain | With Sentry | Diff |
---|---|---|---|
b1e8712+dirty | 7.15 MiB | 8.04 MiB | 912.27 KiB |
07e58c9+dirty | 7.15 MiB | 8.35 MiB | 1.20 MiB |
7bc4d75+dirty | 7.15 MiB | 8.35 MiB | 1.20 MiB |
12427f4+dirty | 7.15 MiB | 8.12 MiB | 997.78 KiB |
9282172+dirty | 7.15 MiB | 8.37 MiB | 1.22 MiB |
43e66e0+dirty | 7.15 MiB | 8.37 MiB | 1.22 MiB |
eb1e19f+dirty | 7.15 MiB | 8.35 MiB | 1.20 MiB |
8e80789+dirty | 7.15 MiB | 8.37 MiB | 1.22 MiB |
cdf2bdf+dirty | 7.15 MiB | 8.38 MiB | 1.23 MiB |
e1ea4a8+dirty | 7.15 MiB | 8.35 MiB | 1.20 MiB |
Previous results on branch: antonis/3859-newCaptureFeedbackAPI-Form
Startup times
Revision | Plain | With Sentry | Diff |
---|---|---|---|
a3ba405+dirty | 359.67 ms | 436.86 ms | 77.19 ms |
e0624b6+dirty | 359.30 ms | 397.94 ms | 38.64 ms |
38a278b+dirty | 392.43 ms | 442.41 ms | 49.97 ms |
cadf235+dirty | 455.51 ms | 451.64 ms | -3.87 ms |
41e9784+dirty | 372.23 ms | 395.22 ms | 22.99 ms |
50c70c0+dirty | 385.30 ms | 433.06 ms | 47.76 ms |
edc8020+dirty | 393.94 ms | 407.87 ms | 13.93 ms |
03c9048+dirty | 397.35 ms | 417.73 ms | 20.37 ms |
f4a5053+dirty | 391.02 ms | 427.04 ms | 36.02 ms |
d33790a+dirty | 404.87 ms | 473.06 ms | 68.19 ms |
App size
Revision | Plain | With Sentry | Diff |
---|---|---|---|
a3ba405+dirty | 7.15 MiB | 8.37 MiB | 1.22 MiB |
e0624b6+dirty | 7.15 MiB | 8.38 MiB | 1.23 MiB |
38a278b+dirty | 7.15 MiB | 8.38 MiB | 1.23 MiB |
cadf235+dirty | 7.15 MiB | 8.37 MiB | 1.22 MiB |
41e9784+dirty | 7.15 MiB | 8.38 MiB | 1.23 MiB |
50c70c0+dirty | 7.15 MiB | 8.38 MiB | 1.23 MiB |
edc8020+dirty | 7.15 MiB | 8.38 MiB | 1.23 MiB |
03c9048+dirty | 7.15 MiB | 8.38 MiB | 1.23 MiB |
f4a5053+dirty | 7.15 MiB | 8.38 MiB | 1.23 MiB |
d33790a+dirty | 7.15 MiB | 8.38 MiB | 1.23 MiB |
iOS (new) Performance metrics 🚀
|
Revision | Plain | With Sentry | Diff |
---|---|---|---|
484813b+dirty | 1225.07 ms | 1221.00 ms | -4.07 ms |
5a22220+dirty | 1246.18 ms | 1249.61 ms | 3.43 ms |
13f280b+dirty | 1217.73 ms | 1229.08 ms | 11.35 ms |
d7401ac+dirty | 1288.10 ms | 1289.54 ms | 1.44 ms |
8fe7c9d+dirty | 1227.63 ms | 1245.28 ms | 17.65 ms |
9385d74+dirty | 1239.51 ms | 1245.88 ms | 6.37 ms |
cdf2f33+dirty | 1210.00 ms | 1218.50 ms | 8.50 ms |
2534337+dirty | 1220.87 ms | 1221.47 ms | 0.60 ms |
4297324+dirty | 1240.86 ms | 1232.04 ms | -8.81 ms |
12427f4+dirty | 1224.90 ms | 1231.40 ms | 6.50 ms |
App size
Revision | Plain | With Sentry | Diff |
---|---|---|---|
484813b+dirty | 2.92 MiB | 3.64 MiB | 740.56 KiB |
5a22220+dirty | 2.92 MiB | 3.48 MiB | 575.81 KiB |
13f280b+dirty | 2.92 MiB | 3.66 MiB | 758.67 KiB |
d7401ac+dirty | 2.92 MiB | 3.40 MiB | 488.06 KiB |
8fe7c9d+dirty | 3.19 MiB | 4.24 MiB | 1.06 MiB |
9385d74+dirty | 2.92 MiB | 3.67 MiB | 772.40 KiB |
cdf2f33+dirty | 2.92 MiB | 3.66 MiB | 755.50 KiB |
2534337+dirty | 2.92 MiB | 3.43 MiB | 529.76 KiB |
4297324+dirty | 2.92 MiB | 3.64 MiB | 741.22 KiB |
12427f4+dirty | 2.92 MiB | 3.44 MiB | 533.29 KiB |
Previous results on branch: antonis/3859-newCaptureFeedbackAPI-Form
Startup times
Revision | Plain | With Sentry | Diff |
---|---|---|---|
d33790a+dirty | 1247.14 ms | 1242.86 ms | -4.28 ms |
0781f75+dirty | 1247.90 ms | 1237.11 ms | -10.79 ms |
edc8020+dirty | 1245.50 ms | 1241.70 ms | -3.80 ms |
561640f+dirty | 1237.10 ms | 1229.59 ms | -7.51 ms |
26fc306+dirty | 1229.10 ms | 1227.88 ms | -1.22 ms |
03c9048+dirty | 1231.52 ms | 1225.96 ms | -5.56 ms |
27e1bf3+dirty | 1245.78 ms | 1244.38 ms | -1.40 ms |
f4a5053+dirty | 1233.04 ms | 1240.02 ms | 6.98 ms |
e0624b6+dirty | 1229.19 ms | 1232.18 ms | 3.00 ms |
a06f6ba+dirty | 1235.31 ms | 1238.76 ms | 3.45 ms |
App size
Revision | Plain | With Sentry | Diff |
---|---|---|---|
d33790a+dirty | 2.92 MiB | 3.67 MiB | 773.59 KiB |
0781f75+dirty | 2.92 MiB | 3.67 MiB | 773.83 KiB |
edc8020+dirty | 2.92 MiB | 3.69 MiB | 793.89 KiB |
561640f+dirty | 2.92 MiB | 3.67 MiB | 773.72 KiB |
26fc306+dirty | 2.92 MiB | 3.67 MiB | 773.77 KiB |
03c9048+dirty | 2.92 MiB | 3.67 MiB | 774.29 KiB |
27e1bf3+dirty | 2.92 MiB | 3.67 MiB | 773.54 KiB |
f4a5053+dirty | 2.92 MiB | 3.67 MiB | 774.18 KiB |
e0624b6+dirty | 2.92 MiB | 3.67 MiB | 773.62 KiB |
a06f6ba+dirty | 2.92 MiB | 3.67 MiB | 773.87 KiB |
iOS (legacy) Performance metrics 🚀
|
Revision | Plain | With Sentry | Diff |
---|---|---|---|
484813b+dirty | 1222.45 ms | 1220.79 ms | -1.66 ms |
5a22220+dirty | 1209.49 ms | 1220.94 ms | 11.45 ms |
13f280b+dirty | 1229.25 ms | 1226.10 ms | -3.15 ms |
d7401ac+dirty | 1252.38 ms | 1275.04 ms | 22.66 ms |
8fe7c9d+dirty | 1241.83 ms | 1244.35 ms | 2.51 ms |
9385d74+dirty | 1215.18 ms | 1216.43 ms | 1.25 ms |
cdf2f33+dirty | 1227.71 ms | 1233.94 ms | 6.22 ms |
2534337+dirty | 1225.08 ms | 1230.26 ms | 5.17 ms |
4297324+dirty | 1230.27 ms | 1232.53 ms | 2.27 ms |
12427f4+dirty | 1267.15 ms | 1271.30 ms | 4.15 ms |
App size
Revision | Plain | With Sentry | Diff |
---|---|---|---|
484813b+dirty | 2.36 MiB | 3.08 MiB | 734.18 KiB |
5a22220+dirty | 2.36 MiB | 2.92 MiB | 570.21 KiB |
13f280b+dirty | 2.36 MiB | 3.10 MiB | 753.43 KiB |
d7401ac+dirty | 2.36 MiB | 2.83 MiB | 481.14 KiB |
8fe7c9d+dirty | 2.63 MiB | 3.68 MiB | 1.04 MiB |
9385d74+dirty | 2.36 MiB | 3.10 MiB | 759.78 KiB |
cdf2f33+dirty | 2.36 MiB | 3.10 MiB | 751.38 KiB |
2534337+dirty | 2.36 MiB | 2.88 MiB | 525.47 KiB |
4297324+dirty | 2.36 MiB | 3.08 MiB | 735.61 KiB |
12427f4+dirty | 2.36 MiB | 2.88 MiB | 530.38 KiB |
Previous results on branch: antonis/3859-newCaptureFeedbackAPI-Form
Startup times
Revision | Plain | With Sentry | Diff |
---|---|---|---|
d33790a+dirty | 1234.19 ms | 1231.76 ms | -2.43 ms |
0781f75+dirty | 1222.19 ms | 1222.11 ms | -0.08 ms |
edc8020+dirty | 1235.24 ms | 1236.69 ms | 1.44 ms |
561640f+dirty | 1220.45 ms | 1227.02 ms | 6.57 ms |
26fc306+dirty | 1227.25 ms | 1225.85 ms | -1.40 ms |
03c9048+dirty | 1235.37 ms | 1238.15 ms | 2.77 ms |
27e1bf3+dirty | 1230.92 ms | 1232.33 ms | 1.41 ms |
f4a5053+dirty | 1225.32 ms | 1231.47 ms | 6.15 ms |
e0624b6+dirty | 1221.86 ms | 1226.42 ms | 4.57 ms |
a06f6ba+dirty | 1230.45 ms | 1227.09 ms | -3.36 ms |
App size
Revision | Plain | With Sentry | Diff |
---|---|---|---|
d33790a+dirty | 2.36 MiB | 3.11 MiB | 761.06 KiB |
0781f75+dirty | 2.36 MiB | 3.11 MiB | 761.35 KiB |
edc8020+dirty | 2.36 MiB | 3.13 MiB | 782.76 KiB |
561640f+dirty | 2.36 MiB | 3.11 MiB | 761.19 KiB |
26fc306+dirty | 2.36 MiB | 3.11 MiB | 761.18 KiB |
03c9048+dirty | 2.36 MiB | 3.11 MiB | 761.74 KiB |
27e1bf3+dirty | 2.36 MiB | 3.11 MiB | 761.03 KiB |
f4a5053+dirty | 2.36 MiB | 3.11 MiB | 761.72 KiB |
e0624b6+dirty | 2.36 MiB | 3.11 MiB | 761.16 KiB |
a06f6ba+dirty | 2.36 MiB | 3.11 MiB | 761.35 KiB |
# Conflicts: # CHANGELOG.md
# Conflicts: # CHANGELOG.md
* Adds sentry branding logo as a base64 encoded png --------- Co-authored-by: LucasZF <[email protected]>
CHANGELOG.md
Outdated
@@ -62,6 +62,27 @@ | |||
|
|||
To learn how to attach context data to the feedback visit [the documentation](https://docs.sentry.io/platforms/react-native/user-feedback/). | |||
|
|||
- User Feedback Form Component Beta ([#4320](https://github.com/getsentry/sentry-react-native/pull/4328)) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Fixed with 9853630
let feedbackFormHandler: (() => void) | null = null; | ||
|
||
const setFeedbackFormHandler = (handler: () => void): void => { | ||
feedbackFormHandler = handler; | ||
}; | ||
|
||
const clearFeedbackFormHandler = (): void => { | ||
feedbackFormHandler = null; | ||
}; | ||
|
||
type Navigation = { | ||
navigate: (screen: string, params?: Record<string, unknown>) => void; | ||
}; | ||
|
||
export const showFeedbackForm = (navigation: Navigation): void => { | ||
setFeedbackFormHandler(() => { | ||
navigation?.navigate?.('FeedbackForm'); | ||
}); | ||
if (feedbackFormHandler) { | ||
feedbackFormHandler(); | ||
} else { | ||
logger.error('FeedbackForm handler is not set. Please ensure it is initialized.'); | ||
} | ||
}; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This was merged from #4370
I would keep the auto inject out of the this PR.
I think we should not export this helper, because to use it user still have to create a screen which will present the FeedbackForm
component. Only then the helper shows the form.
The auto inject should work without manually specifying the FeedbackForm component and should be independent of any nav library. (We can create helper for specific bav libs later...)
I imagine when I call showFeedbackForm()
the form will just show, no need to setup anything besides Sentry.init
/Sentry.wrap
(since we can't inject to dom as on web).
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Makes sense @krystofwoldrich 👍
I reverted the change with e7a9484 and will iterate on the auto inject on a separate PR.
This reverts commit da0e3ea.
# Conflicts: # CHANGELOG.md
To avoid blocking the chain of the feedback PRs, I changed the target to https://github.com/getsentry/sentry-react-native/tree/feedback-ui Where we can merge all the current PRs after they are reviewed and then we can merge https://github.com/getsentry/sentry-react-native/tree/feedback-ui to main and release the first feedback beta. |
|
||
public handleFeedbackSubmit: () => void = () => { | ||
const { name, email, description } = this.state; | ||
const { onFormClose } = this.props; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is addressed in https://github.com/getsentry/sentry-react-native/pull/4364/files
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you, just did a last check and run the sample, looks great!
Thank you @krystofwoldrich 🙇 |
📢 Type of change
📜 Description
Adds a basic feedback form with the following fields: name, email, description.
The form text and styles can be customised.
Subtask PRs:
(2.3) Auto-inject feedback widget #4370💡 Motivation and Context
Fixes #4336
💚 How did you test it?
CI, Manual testing (example)
📝 Checklist
sendDefaultPII
is enabled🔮 Next steps