import 'package:flutter_riverpod/flutter_riverpod.dart';
import 'package:niogu_app/core/providers/app_provider.dart';
import 'package:niogu_app/features/stock_check/data/repositories/stock_checked_repository_impl.dart';
import 'package:niogu_app/features/stock_check/domain/entities/selected_checked_item.dart';
import 'package:niogu_app/features/stock_check/domain/repositories/i_stock_checked_repository.dart';
import 'package:niogu_app/features/stock_check/presentation/controllers/stock_check_controller.dart';

final stockCheckedRepository = Provider.autoDispose<IStockCheckedRepository>((
  ref,
) {
  final appDatabase = ref.watch(appDatabaseProvider);
  return StockCheckedRepositoryImpl(appDatabase);
});

final selectedCheckedItemProvider =
    StateProvider.autoDispose<Map<String, SelectedCheckedItem>>((ref) => {});

final stockCheckedControllerProvider =
    AsyncNotifierProvider.autoDispose<StockCheckController, void>(
      StockCheckController.new,
    );
