♻️ Improved new notifcation style

This commit is contained in:
2026-01-15 01:04:15 +08:00
parent d639df7623
commit 476da28b5e
11 changed files with 414 additions and 75 deletions

View File

@@ -0,0 +1,63 @@
// GENERATED CODE - DO NOT MODIFY BY HAND
part of 'notification.dart';
// **************************************************************************
// RiverpodGenerator
// **************************************************************************
// GENERATED CODE - DO NOT MODIFY BY HAND
// ignore_for_file: type=lint, type=warning
@ProviderFor(NotificationState)
final notificationStateProvider = NotificationStateProvider._();
final class NotificationStateProvider
extends $NotifierProvider<NotificationState, List<NotificationItem>> {
NotificationStateProvider._()
: super(
from: null,
argument: null,
retry: null,
name: r'notificationStateProvider',
isAutoDispose: true,
dependencies: null,
$allTransitiveDependencies: null,
);
@override
String debugGetCreateSourceHash() => _$notificationStateHash();
@$internal
@override
NotificationState create() => NotificationState();
/// {@macro riverpod.override_with_value}
Override overrideWithValue(List<NotificationItem> value) {
return $ProviderOverride(
origin: this,
providerOverride: $SyncValueProvider<List<NotificationItem>>(value),
);
}
}
String _$notificationStateHash() => r'8625e77d28d71237d86f6d06efab437aa7c09df1';
abstract class _$NotificationState extends $Notifier<List<NotificationItem>> {
List<NotificationItem> build();
@$mustCallSuper
@override
void runBuild() {
final ref =
this.ref as $Ref<List<NotificationItem>, List<NotificationItem>>;
final element =
ref.element
as $ClassProviderElement<
AnyNotifier<List<NotificationItem>, List<NotificationItem>>,
List<NotificationItem>,
Object?,
Object?
>;
element.handleCreate(ref, build);
}
}