part of 'routine_bloc.dart'; class RoutineState extends Equatable { final List> ifItems; final List> thenItems; final List> availableCards; final List scenes; final List automations; final Map> selectedFunctions; final bool isLoading; final String? errorMessage; final String? loadScenesErrorMessage; final String? loadAutomationErrorMessage; final String? routineName; final String? selectedIcon; final String? searchText; const RoutineState( {this.ifItems = const [], this.thenItems = const [], this.availableCards = const [], this.scenes = const [], this.automations = const [], this.selectedFunctions = const {}, this.isLoading = false, this.errorMessage, this.routineName, this.selectedIcon, this.loadScenesErrorMessage, this.loadAutomationErrorMessage, this.searchText}); RoutineState copyWith( {List>? ifItems, List>? thenItems, List? scenes, List? automations, Map>? selectedFunctions, bool? isLoading, String? errorMessage, String? routineName, String? selectedIcon, String? loadAutomationErrorMessage, String? loadScenesErrorMessage, String? searchText}) { return RoutineState( ifItems: ifItems ?? this.ifItems, thenItems: thenItems ?? this.thenItems, scenes: scenes ?? this.scenes, automations: automations ?? this.automations, selectedFunctions: selectedFunctions ?? this.selectedFunctions, isLoading: isLoading ?? this.isLoading, errorMessage: errorMessage ?? this.errorMessage, routineName: routineName ?? this.routineName, selectedIcon: selectedIcon ?? this.selectedIcon, loadScenesErrorMessage: loadScenesErrorMessage ?? this.loadScenesErrorMessage, loadAutomationErrorMessage: loadAutomationErrorMessage ?? this.loadAutomationErrorMessage, searchText: searchText ?? this.searchText); } @override List get props => [ ifItems, thenItems, scenes, automations, selectedFunctions, isLoading, errorMessage, routineName, selectedIcon, loadScenesErrorMessage, loadAutomationErrorMessage, searchText ]; }