// 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<PromotionsNotifier, List<Promotion>> {
  /// 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<List<Promotion>> {
  FutureOr<List<Promotion>> build();
  @$mustCallSuper
  @override
  void runBuild() {
    final created = build();
    final ref = this.ref as $Ref<AsyncValue<List<Promotion>>, List<Promotion>>;
    final element =
        ref.element
            as $ClassProviderElement<
              AnyNotifier<AsyncValue<List<Promotion>>, List<Promotion>>,
              AsyncValue<List<Promotion>>,
              Object?,
              Object?
            >;
    element.handleValue(ref, created);
  }
}
