File tree 3 files changed +31
-1
lines changed
android/src/main/java/com/instabug/reactlibrary
3 files changed +31
-1
lines changed Original file line number Diff line number Diff line change @@ -1472,6 +1472,21 @@ public void setSessionProfilerEnabled(boolean sessionProfilerEnabled) {
1472
1472
}
1473
1473
}
1474
1474
1475
+ /**
1476
+ * Set Surveys welcome screen enabled, default value is false
1477
+ *
1478
+ * @param shouldShow shouldShow whether should a welcome screen be shown
1479
+ * before taking surveys or not
1480
+ */
1481
+ @ ReactMethod
1482
+ public void setShouldShowSurveysWelcomeScreen (boolean shouldShow ) {
1483
+ try {
1484
+ InstabugSurvey .setShouldShowSurveysWelcomeScreen (shouldShow );
1485
+ } catch (java .lang .Exception exception ) {
1486
+ exception .printStackTrace ();
1487
+ }
1488
+ }
1489
+
1475
1490
private InstabugCustomTextPlaceHolder .Key getStringToKeyConstant (String key ) {
1476
1491
switch (key ) {
1477
1492
case SHAKE_HINT :
Original file line number Diff line number Diff line change @@ -928,7 +928,7 @@ module.exports = {
928
928
} else {
929
929
Instabug . sendHandledJSCrash ( jsonObject ) ;
930
930
}
931
- } ,
931
+ } ,
932
932
933
933
/**
934
934
* Sets the default position at which the Instabug screen recording button will be shown.
@@ -972,6 +972,17 @@ module.exports = {
972
972
Instabug . showFeatureRequests ( ) ;
973
973
} ,
974
974
975
+ /**
976
+ * Setting an option for all the surveys to show a welcome screen before
977
+ * the user starts taking the survey.
978
+ * @param shouldShowWelcomeScreen A boolean for setting whether the
979
+ * welcome screen should show.
980
+ *
981
+ */
982
+ setShouldShowSurveysWelcomeScreen : function ( shouldShowWelcomeScreen ) {
983
+ Instabug . setShouldShowSurveysWelcomeScreen ( shouldShowWelcomeScreen ) ;
984
+ } ,
985
+
975
986
/**
976
987
* The event used to invoke the feedback form
977
988
* @readonly
Original file line number Diff line number Diff line change @@ -410,6 +410,10 @@ - (dispatch_queue_t)methodQueue {
410
410
[Instabug showFeatureRequests ];
411
411
}
412
412
413
+ RCT_EXPORT_METHOD (setShouldShowSurveysWelcomeScreen:(BOOL )shouldShowWelcomeScreen) {
414
+ [Instabug setShouldShowSurveysWelcomeScreen: shouldShowWelcomeScreen];
415
+ }
416
+
413
417
RCT_EXPORT_METHOD (isRunningLive:(RCTResponseSenderBlock)callback) {
414
418
BOOL result = NO ;
415
419
#if TARGET_OS_SIMULATOR
You can’t perform that action at this time.
0 commit comments