content: import 'package:sfera/component.dart';
  
  class TrainJourneySettings {
    const TrainJourneySettings({
      this.selectedBreakSeries,
      this.expandedGroups = const [],
      this.isAutoAdvancementEnabled = true,
      this.isManeuverModeEnabled = false,
    });
  
    final BreakSeries? selectedBreakSeries;
    final List<int> expandedGroups;
    final bool isAutoAdvancementEnabled;
    final bool isManeuverModeEnabled;
  
    TrainJourneySettings copyWith({
      BreakSeries? selectedBreakSeries,
      List<int>? expandedGroups,
      bool? isAutoAdvancementEnabled,
      bool? isManeuverModeEnabled,
    }) {
      return TrainJourneySettings(
        selectedBreakSeries: selectedBreakSeries ?? this.selectedBreakSeries,
        expandedGroups: expandedGroups ?? this.expandedGroups,
        isAutoAdvancementEnabled: isAutoAdvancementEnabled ?? this.isAutoAdvancementEnabled,
        isManeuverModeEnabled: isManeuverModeEnabled ?? this.isManeuverModeEnabled,
      );
    }
  
    BreakSeries? resolvedBreakSeries(Metadata? metadata) {
      return selectedBreakSeries ?? metadata?.breakSeries;
    }
  }
  