import 'package:flutter/cupertino.dart';
import 'package:hl_lieferservice/feature/delivery/detail/presentation/steps/step_article_management.dart';
import 'package:hl_lieferservice/feature/delivery/detail/presentation/steps/step_delivery_options.dart';
import 'package:hl_lieferservice/feature/delivery/detail/presentation/steps/step_info.dart';
import 'package:hl_lieferservice/feature/delivery/detail/presentation/steps/step_note.dart';
import 'package:hl_lieferservice/feature/delivery/detail/presentation/steps/step_summary.dart';
import 'package:hl_lieferservice/model/delivery.dart';

abstract class IStepFactory {
  Widget? make(int step, Delivery delivery);
}

class StepFactory extends IStepFactory {
  @override
  Widget? make(int step, Delivery delivery) {
    switch(step) {
      case 0:
        return DeliveryStepInfo(delivery: delivery);
      case 1:
        return DeliveryStepNote(delivery: delivery);
      case 2:
        return DeliveryStepArticleManagement(delivery: delivery);
      case 3:
        return DeliveryStepOptions(delivery: delivery);
      case 4:
        return DeliveryStepSummary(delivery: delivery);
    }

    return null;
  }

}