Line data Source code
1 : import 'package:fast_immutable_collections/fast_immutable_collections.dart';
2 : import 'package:freezed_annotation/freezed_annotation.dart';
3 : import 'package:redfire/types.dart';
4 :
5 : import 'step_model.dart';
6 :
7 : part 'steps_state.freezed.dart';
8 : part 'steps_state.g.dart';
9 :
10 : @freezed
11 : class StepsState with _$StepsState, ReduxState {
12 : static const String className = 'StepsState';
13 :
14 5 : const StepsState._();
15 : const factory StepsState(
16 : {StepModel? selected, required ISet<StepModel> all}) = _StepsState;
17 :
18 0 : factory StepsState.fromJson(JsonMap json) => _$StepsStateFromJson(json);
19 :
20 15 : factory StepsState.init() => StepsState(all: ISet());
21 :
22 0 : @override
23 : String get typeName => className;
24 : }
|