Skip to content

Commit 502c614

Browse files
author
UnnatiCP
committed
Added Disabling/Enabling App Banners methods in flutter doc
Added Disabling/Enabling App Banners methods in flutter doc
1 parent 0465f3d commit 502c614

3 files changed

Lines changed: 46 additions & 12 deletions

File tree

docs/sdks/android/methods.md

Lines changed: 12 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1041,7 +1041,9 @@ CleverPush.getInstance(this).removeNotification("Notification ID", true)
10411041

10421042
**Remove all notifications from local storage**
10431043

1044-
You can remove all notifications stored locally using the following method:
1044+
(Available from version 1.35.23)
1045+
1046+
You can remove all notifications stored locally using the following method (this does not clear any notifications from notification center):
10451047

10461048
<!--DOCUSAURUS_CODE_TABS-->
10471049

@@ -1201,10 +1203,13 @@ CleverPush.getInstance(this).setCustomActivity(activity)
12011203
<!--END_DOCUSAURUS_CODE_TABS-->
12021204

12031205

1204-
### Disabling banners
1206+
### Disabling/Enabling App Banners
1207+
1208+
App banners are enabled by default.
12051209

1206-
You can also disable app banners temporarily, e.g. during a splash screen. Banners are enabled by default.
1207-
If a banner would show during this time, it is added to an internal queue and shown when calling `enableAppBanners`.
1210+
You can temporarily disable app banners, for example during a splash screen or while navigating between screens.
1211+
1212+
If a banner is triggered while banners are disabled, it will be added to an internal queue and automatically displayed once `enableAppBanners()` is called.
12081213

12091214
<!--DOCUSAURUS_CODE_TABS-->
12101215

@@ -1227,7 +1232,9 @@ CleverPush.getInstance(this).enableAppBanners()
12271232

12281233
### Development mode
12291234

1230-
You can enable the development mode to disable caches for app banners, so you always see the most up to date version.
1235+
You can enable Development Mode to temporarily disable app banner caching.
1236+
1237+
This ensures that you always see the most up-to-date version of app banners during development and testing.
12311238

12321239
<!--DOCUSAURUS_CODE_TABS-->
12331240

docs/sdks/flutter/methods.md

Lines changed: 31 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -258,6 +258,29 @@ CleverPush.shared.showAppBanner("APP_BANNER_ID", () {
258258
});
259259
```
260260

261+
### Disabling/Enabling App Banners
262+
263+
App banners are enabled by default.
264+
265+
You can temporarily disable app banners, for example during a splash screen or while navigating between screens.
266+
267+
If a banner is triggered while banners are disabled, it will be added to an internal queue and automatically displayed once `enableAppBanners()` is called.
268+
269+
```dart
270+
CleverPush.shared.disableAppBanners();
271+
CleverPush.shared.enableAppBanners();
272+
```
273+
274+
### Development mode
275+
276+
You can enable Development Mode to temporarily disable app banner caching.
277+
278+
This ensures that you always see the most up-to-date version of app banners during development and testing.
279+
280+
```dart
281+
CleverPush.shared.enableDevelopmentMode();
282+
```
283+
261284
## Tracking Consent
262285

263286
You can optionally require a tracking consent from the user (e.g. you get this consent from a CMP). If you tell our SDK to wait for the tracking consent, it will not call any tracking-related features until the consent is available. Calls will be queued and automatically executed until the consent is available.
@@ -306,20 +329,22 @@ CleverPush.shared.removeNotification(
306329
);
307330
```
308331

309-
**Remove all notifications from local storage**
332+
**Clear all notifications from the notification center**
310333

311-
You can remove all notifications stored locally using the following method:
334+
You can remove all notifications from the notification center only (this does not clear locally stored notifications):
312335

313336
```dart
314-
CleverPush.shared.removeAllNotifications();
337+
CleverPush.shared.clearNotificationsFromNotificationCenter();
315338
```
316339

317-
**Clear all notifications from the notification center**
340+
**Remove all notifications from local storage**
318341

319-
You can remove all notifications from the notification center only (this does not clear locally stored notifications):
342+
(Available from version 1.23.31)
343+
344+
You can remove all notifications stored locally using the following method (this does not clear any notifications from notification center):
320345

321346
```dart
322-
CleverPush.shared.clearNotificationsFromNotificationCenter();
347+
CleverPush.shared.removeAllNotifications();
323348
```
324349

325350
## Handle Universal Links In App (iOS)

docs/sdks/ios/methods.md

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -427,7 +427,9 @@ CleverPush.removeNotification("notification_Id")
427427
428428
**Remove all notifications from local storage**
429429
430-
You can remove all notifications stored locally using the following method:
430+
(Available from version 1.34.37)
431+
432+
You can remove all notifications stored locally using the following method (this does not clear any notifications from notification center):
431433
432434
<!--DOCUSAURUS_CODE_TABS-->
433435

0 commit comments

Comments
 (0)