// GENERATED CODE - DO NOT MODIFY BY HAND part of 'promotions_provider.dart'; // ************************************************************************** // RiverpodGenerator // ************************************************************************** // GENERATED CODE - DO NOT MODIFY BY HAND // ignore_for_file: type=lint, type=warning /// Promotions Provider /// /// Fetches and caches the list of active promotions. /// Automatically handles loading, error, and data states. /// /// Usage: /// ```dart /// // In a ConsumerWidget /// final promotionsAsync = ref.watch(promotionsProvider); /// /// promotionsAsync.when( /// data: (promotions) => PromotionSlider(promotions: promotions), /// loading: () => CircularProgressIndicator(), /// error: (error, stack) => ErrorWidget(error), /// ); /// ``` @ProviderFor(PromotionsNotifier) const promotionsProvider = PromotionsNotifierProvider._(); /// Promotions Provider /// /// Fetches and caches the list of active promotions. /// Automatically handles loading, error, and data states. /// /// Usage: /// ```dart /// // In a ConsumerWidget /// final promotionsAsync = ref.watch(promotionsProvider); /// /// promotionsAsync.when( /// data: (promotions) => PromotionSlider(promotions: promotions), /// loading: () => CircularProgressIndicator(), /// error: (error, stack) => ErrorWidget(error), /// ); /// ``` final class PromotionsNotifierProvider extends $AsyncNotifierProvider> { /// Promotions Provider /// /// Fetches and caches the list of active promotions. /// Automatically handles loading, error, and data states. /// /// Usage: /// ```dart /// // In a ConsumerWidget /// final promotionsAsync = ref.watch(promotionsProvider); /// /// promotionsAsync.when( /// data: (promotions) => PromotionSlider(promotions: promotions), /// loading: () => CircularProgressIndicator(), /// error: (error, stack) => ErrorWidget(error), /// ); /// ``` const PromotionsNotifierProvider._() : super( from: null, argument: null, retry: null, name: r'promotionsProvider', isAutoDispose: true, dependencies: null, $allTransitiveDependencies: null, ); @override String debugGetCreateSourceHash() => _$promotionsNotifierHash(); @$internal @override PromotionsNotifier create() => PromotionsNotifier(); } String _$promotionsNotifierHash() => r'3cd866c74ba11c6519e9b63521e1757ef117c7a9'; /// Promotions Provider /// /// Fetches and caches the list of active promotions. /// Automatically handles loading, error, and data states. /// /// Usage: /// ```dart /// // In a ConsumerWidget /// final promotionsAsync = ref.watch(promotionsProvider); /// /// promotionsAsync.when( /// data: (promotions) => PromotionSlider(promotions: promotions), /// loading: () => CircularProgressIndicator(), /// error: (error, stack) => ErrorWidget(error), /// ); /// ``` abstract class _$PromotionsNotifier extends $AsyncNotifier> { FutureOr> build(); @$mustCallSuper @override void runBuild() { final created = build(); final ref = this.ref as $Ref>, List>; final element = ref.element as $ClassProviderElement< AnyNotifier>, List>, AsyncValue>, Object?, Object? >; element.handleValue(ref, created); } }