chore: update app version to 1.9.0, change Flutter build mode to debug, and add changes field to app info model for update dialogs
This commit is contained in:
@@ -19,6 +19,7 @@ abstract class Info with _$Info {
|
||||
String? minVersion,
|
||||
String? module,
|
||||
bool? required,
|
||||
List<String>? changes,
|
||||
}) = _Info;
|
||||
|
||||
factory Info.fromJson(Map<String, dynamic> json) => _$InfoFromJson(json);
|
||||
|
||||
@@ -308,7 +308,7 @@ $InfoCopyWith<$Res>? get info {
|
||||
/// @nodoc
|
||||
mixin _$Info {
|
||||
|
||||
String? get version; String? get minVersion; String? get module; bool? get required;
|
||||
String? get version; String? get minVersion; String? get module; bool? get required; List<String>? get changes;
|
||||
/// Create a copy of Info
|
||||
/// with the given fields replaced by the non-null parameter values.
|
||||
@JsonKey(includeFromJson: false, includeToJson: false)
|
||||
@@ -321,16 +321,16 @@ $InfoCopyWith<Info> get copyWith => _$InfoCopyWithImpl<Info>(this as Info, _$ide
|
||||
|
||||
@override
|
||||
bool operator ==(Object other) {
|
||||
return identical(this, other) || (other.runtimeType == runtimeType&&other is Info&&(identical(other.version, version) || other.version == version)&&(identical(other.minVersion, minVersion) || other.minVersion == minVersion)&&(identical(other.module, module) || other.module == module)&&(identical(other.required, required) || other.required == required));
|
||||
return identical(this, other) || (other.runtimeType == runtimeType&&other is Info&&(identical(other.version, version) || other.version == version)&&(identical(other.minVersion, minVersion) || other.minVersion == minVersion)&&(identical(other.module, module) || other.module == module)&&(identical(other.required, required) || other.required == required)&&const DeepCollectionEquality().equals(other.changes, changes));
|
||||
}
|
||||
|
||||
@JsonKey(includeFromJson: false, includeToJson: false)
|
||||
@override
|
||||
int get hashCode => Object.hash(runtimeType,version,minVersion,module,required);
|
||||
int get hashCode => Object.hash(runtimeType,version,minVersion,module,required,const DeepCollectionEquality().hash(changes));
|
||||
|
||||
@override
|
||||
String toString() {
|
||||
return 'Info(version: $version, minVersion: $minVersion, module: $module, required: $required)';
|
||||
return 'Info(version: $version, minVersion: $minVersion, module: $module, required: $required, changes: $changes)';
|
||||
}
|
||||
|
||||
|
||||
@@ -341,7 +341,7 @@ abstract mixin class $InfoCopyWith<$Res> {
|
||||
factory $InfoCopyWith(Info value, $Res Function(Info) _then) = _$InfoCopyWithImpl;
|
||||
@useResult
|
||||
$Res call({
|
||||
String? version, String? minVersion, String? module, bool? required
|
||||
String? version, String? minVersion, String? module, bool? required, List<String>? changes
|
||||
});
|
||||
|
||||
|
||||
@@ -358,13 +358,14 @@ class _$InfoCopyWithImpl<$Res>
|
||||
|
||||
/// Create a copy of Info
|
||||
/// with the given fields replaced by the non-null parameter values.
|
||||
@pragma('vm:prefer-inline') @override $Res call({Object? version = freezed,Object? minVersion = freezed,Object? module = freezed,Object? required = freezed,}) {
|
||||
@pragma('vm:prefer-inline') @override $Res call({Object? version = freezed,Object? minVersion = freezed,Object? module = freezed,Object? required = freezed,Object? changes = freezed,}) {
|
||||
return _then(_self.copyWith(
|
||||
version: freezed == version ? _self.version : version // ignore: cast_nullable_to_non_nullable
|
||||
as String?,minVersion: freezed == minVersion ? _self.minVersion : minVersion // ignore: cast_nullable_to_non_nullable
|
||||
as String?,module: freezed == module ? _self.module : module // ignore: cast_nullable_to_non_nullable
|
||||
as String?,required: freezed == required ? _self.required : required // ignore: cast_nullable_to_non_nullable
|
||||
as bool?,
|
||||
as bool?,changes: freezed == changes ? _self.changes : changes // ignore: cast_nullable_to_non_nullable
|
||||
as List<String>?,
|
||||
));
|
||||
}
|
||||
|
||||
@@ -449,10 +450,10 @@ return $default(_that);case _:
|
||||
/// }
|
||||
/// ```
|
||||
|
||||
@optionalTypeArgs TResult maybeWhen<TResult extends Object?>(TResult Function( String? version, String? minVersion, String? module, bool? required)? $default,{required TResult orElse(),}) {final _that = this;
|
||||
@optionalTypeArgs TResult maybeWhen<TResult extends Object?>(TResult Function( String? version, String? minVersion, String? module, bool? required, List<String>? changes)? $default,{required TResult orElse(),}) {final _that = this;
|
||||
switch (_that) {
|
||||
case _Info() when $default != null:
|
||||
return $default(_that.version,_that.minVersion,_that.module,_that.required);case _:
|
||||
return $default(_that.version,_that.minVersion,_that.module,_that.required,_that.changes);case _:
|
||||
return orElse();
|
||||
|
||||
}
|
||||
@@ -470,10 +471,10 @@ return $default(_that.version,_that.minVersion,_that.module,_that.required);case
|
||||
/// }
|
||||
/// ```
|
||||
|
||||
@optionalTypeArgs TResult when<TResult extends Object?>(TResult Function( String? version, String? minVersion, String? module, bool? required) $default,) {final _that = this;
|
||||
@optionalTypeArgs TResult when<TResult extends Object?>(TResult Function( String? version, String? minVersion, String? module, bool? required, List<String>? changes) $default,) {final _that = this;
|
||||
switch (_that) {
|
||||
case _Info():
|
||||
return $default(_that.version,_that.minVersion,_that.module,_that.required);case _:
|
||||
return $default(_that.version,_that.minVersion,_that.module,_that.required,_that.changes);case _:
|
||||
throw StateError('Unexpected subclass');
|
||||
|
||||
}
|
||||
@@ -490,10 +491,10 @@ return $default(_that.version,_that.minVersion,_that.module,_that.required);case
|
||||
/// }
|
||||
/// ```
|
||||
|
||||
@optionalTypeArgs TResult? whenOrNull<TResult extends Object?>(TResult? Function( String? version, String? minVersion, String? module, bool? required)? $default,) {final _that = this;
|
||||
@optionalTypeArgs TResult? whenOrNull<TResult extends Object?>(TResult? Function( String? version, String? minVersion, String? module, bool? required, List<String>? changes)? $default,) {final _that = this;
|
||||
switch (_that) {
|
||||
case _Info() when $default != null:
|
||||
return $default(_that.version,_that.minVersion,_that.module,_that.required);case _:
|
||||
return $default(_that.version,_that.minVersion,_that.module,_that.required,_that.changes);case _:
|
||||
return null;
|
||||
|
||||
}
|
||||
@@ -505,13 +506,22 @@ return $default(_that.version,_that.minVersion,_that.module,_that.required);case
|
||||
@JsonSerializable()
|
||||
|
||||
class _Info implements Info {
|
||||
const _Info({this.version, this.minVersion, this.module, this.required});
|
||||
const _Info({this.version, this.minVersion, this.module, this.required, final List<String>? changes}): _changes = changes;
|
||||
factory _Info.fromJson(Map<String, dynamic> json) => _$InfoFromJson(json);
|
||||
|
||||
@override final String? version;
|
||||
@override final String? minVersion;
|
||||
@override final String? module;
|
||||
@override final bool? required;
|
||||
final List<String>? _changes;
|
||||
@override List<String>? get changes {
|
||||
final value = _changes;
|
||||
if (value == null) return null;
|
||||
if (_changes is EqualUnmodifiableListView) return _changes;
|
||||
// ignore: implicit_dynamic_type
|
||||
return EqualUnmodifiableListView(value);
|
||||
}
|
||||
|
||||
|
||||
/// Create a copy of Info
|
||||
/// with the given fields replaced by the non-null parameter values.
|
||||
@@ -526,16 +536,16 @@ Map<String, dynamic> toJson() {
|
||||
|
||||
@override
|
||||
bool operator ==(Object other) {
|
||||
return identical(this, other) || (other.runtimeType == runtimeType&&other is _Info&&(identical(other.version, version) || other.version == version)&&(identical(other.minVersion, minVersion) || other.minVersion == minVersion)&&(identical(other.module, module) || other.module == module)&&(identical(other.required, required) || other.required == required));
|
||||
return identical(this, other) || (other.runtimeType == runtimeType&&other is _Info&&(identical(other.version, version) || other.version == version)&&(identical(other.minVersion, minVersion) || other.minVersion == minVersion)&&(identical(other.module, module) || other.module == module)&&(identical(other.required, required) || other.required == required)&&const DeepCollectionEquality().equals(other._changes, _changes));
|
||||
}
|
||||
|
||||
@JsonKey(includeFromJson: false, includeToJson: false)
|
||||
@override
|
||||
int get hashCode => Object.hash(runtimeType,version,minVersion,module,required);
|
||||
int get hashCode => Object.hash(runtimeType,version,minVersion,module,required,const DeepCollectionEquality().hash(_changes));
|
||||
|
||||
@override
|
||||
String toString() {
|
||||
return 'Info(version: $version, minVersion: $minVersion, module: $module, required: $required)';
|
||||
return 'Info(version: $version, minVersion: $minVersion, module: $module, required: $required, changes: $changes)';
|
||||
}
|
||||
|
||||
|
||||
@@ -546,7 +556,7 @@ abstract mixin class _$InfoCopyWith<$Res> implements $InfoCopyWith<$Res> {
|
||||
factory _$InfoCopyWith(_Info value, $Res Function(_Info) _then) = __$InfoCopyWithImpl;
|
||||
@override @useResult
|
||||
$Res call({
|
||||
String? version, String? minVersion, String? module, bool? required
|
||||
String? version, String? minVersion, String? module, bool? required, List<String>? changes
|
||||
});
|
||||
|
||||
|
||||
@@ -563,13 +573,14 @@ class __$InfoCopyWithImpl<$Res>
|
||||
|
||||
/// Create a copy of Info
|
||||
/// with the given fields replaced by the non-null parameter values.
|
||||
@override @pragma('vm:prefer-inline') $Res call({Object? version = freezed,Object? minVersion = freezed,Object? module = freezed,Object? required = freezed,}) {
|
||||
@override @pragma('vm:prefer-inline') $Res call({Object? version = freezed,Object? minVersion = freezed,Object? module = freezed,Object? required = freezed,Object? changes = freezed,}) {
|
||||
return _then(_Info(
|
||||
version: freezed == version ? _self.version : version // ignore: cast_nullable_to_non_nullable
|
||||
as String?,minVersion: freezed == minVersion ? _self.minVersion : minVersion // ignore: cast_nullable_to_non_nullable
|
||||
as String?,module: freezed == module ? _self.module : module // ignore: cast_nullable_to_non_nullable
|
||||
as String?,required: freezed == required ? _self.required : required // ignore: cast_nullable_to_non_nullable
|
||||
as bool?,
|
||||
as bool?,changes: freezed == changes ? _self._changes : changes // ignore: cast_nullable_to_non_nullable
|
||||
as List<String>?,
|
||||
));
|
||||
}
|
||||
|
||||
|
||||
@@ -27,6 +27,9 @@ _Info _$InfoFromJson(Map<String, dynamic> json) => _Info(
|
||||
minVersion: json['minVersion'] as String?,
|
||||
module: json['module'] as String?,
|
||||
required: json['required'] as bool?,
|
||||
changes: (json['changes'] as List<dynamic>?)
|
||||
?.map((e) => e as String)
|
||||
.toList(),
|
||||
);
|
||||
|
||||
Map<String, dynamic> _$InfoToJson(_Info instance) => <String, dynamic>{
|
||||
@@ -34,4 +37,5 @@ Map<String, dynamic> _$InfoToJson(_Info instance) => <String, dynamic>{
|
||||
'minVersion': instance.minVersion,
|
||||
'module': instance.module,
|
||||
'required': instance.required,
|
||||
'changes': instance.changes,
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user