implemented a guided notification permission flow triggered on the first Talk visit
This commit is contained in:
@@ -160,7 +160,16 @@ class PushStatusRow {
|
||||
/// for informational details (e.g. the registered URL).
|
||||
final String? detail;
|
||||
|
||||
const PushStatusRow({required this.label, required this.state, this.detail});
|
||||
/// When true, the row offers a shortcut into the OS notification settings —
|
||||
/// the only place the user can (re)grant the permission after a denial.
|
||||
final bool opensNotificationSettings;
|
||||
|
||||
const PushStatusRow({
|
||||
required this.label,
|
||||
required this.state,
|
||||
this.detail,
|
||||
this.opensNotificationSettings = false,
|
||||
});
|
||||
}
|
||||
|
||||
const _pendingDetail =
|
||||
@@ -181,6 +190,7 @@ List<PushStatusRow> buildPushStatusRows(PushStatusReport r) => [
|
||||
PushStatusRow(
|
||||
label: 'Benachrichtigungsberechtigung',
|
||||
state: r.osPermission,
|
||||
opensNotificationSettings: true,
|
||||
detail: switch (r.osPermission) {
|
||||
PushCheck.ok => null,
|
||||
PushCheck.fail =>
|
||||
|
||||
Reference in New Issue
Block a user