mirror of
https://github.com/Dr-Blank/Vaani.git
synced 2026-01-16 07:09:32 +00:00
chore: update flutter and dependencies
This commit is contained in:
parent
06694f5f0b
commit
a520136e01
80 changed files with 7701 additions and 9141 deletions
|
|
@ -11,7 +11,7 @@ part 'library_item_extras.freezed.dart';
|
|||
/// [book] is the book that the item represents
|
||||
/// [heroTagSuffix] is the suffix to use for the hero tag to avoid conflicts
|
||||
@freezed
|
||||
class LibraryItemExtras with _$LibraryItemExtras {
|
||||
sealed class LibraryItemExtras with _$LibraryItemExtras {
|
||||
const factory LibraryItemExtras({
|
||||
BookMinified? book,
|
||||
@Default('') String heroTagSuffix,
|
||||
|
|
|
|||
|
|
@ -1,5 +1,5 @@
|
|||
// coverage:ignore-file
|
||||
// GENERATED CODE - DO NOT MODIFY BY HAND
|
||||
// coverage:ignore-file
|
||||
// ignore_for_file: type=lint
|
||||
// ignore_for_file: unused_element, deprecated_member_use, deprecated_member_use_from_same_package, use_function_type_syntax_for_parameters, unnecessary_const, avoid_init_to_null, invalid_override_different_default_values_named, prefer_expression_function_bodies, annotate_overrides, invalid_annotation_target, unnecessary_question_mark
|
||||
|
||||
|
|
@ -9,156 +9,260 @@ part of 'library_item_extras.dart';
|
|||
// FreezedGenerator
|
||||
// **************************************************************************
|
||||
|
||||
// dart format off
|
||||
T _$identity<T>(T value) => value;
|
||||
|
||||
final _privateConstructorUsedError = UnsupportedError(
|
||||
'It seems like you constructed your class using `MyClass._()`. This constructor is only meant to be used by freezed and you are not supposed to need it nor use it.\nPlease check the documentation here for more information: https://github.com/rrousselGit/freezed#adding-getters-and-methods-to-our-models');
|
||||
|
||||
/// @nodoc
|
||||
mixin _$LibraryItemExtras {
|
||||
BookMinified? get book => throw _privateConstructorUsedError;
|
||||
String get heroTagSuffix => throw _privateConstructorUsedError;
|
||||
|
||||
/// Create a copy of LibraryItemExtras
|
||||
/// with the given fields replaced by the non-null parameter values.
|
||||
@JsonKey(includeFromJson: false, includeToJson: false)
|
||||
$LibraryItemExtrasCopyWith<LibraryItemExtras> get copyWith =>
|
||||
throw _privateConstructorUsedError;
|
||||
BookMinified? get book; String get heroTagSuffix;
|
||||
/// Create a copy of LibraryItemExtras
|
||||
/// with the given fields replaced by the non-null parameter values.
|
||||
@JsonKey(includeFromJson: false, includeToJson: false)
|
||||
@pragma('vm:prefer-inline')
|
||||
$LibraryItemExtrasCopyWith<LibraryItemExtras> get copyWith => _$LibraryItemExtrasCopyWithImpl<LibraryItemExtras>(this as LibraryItemExtras, _$identity);
|
||||
|
||||
|
||||
|
||||
@override
|
||||
bool operator ==(Object other) {
|
||||
return identical(this, other) || (other.runtimeType == runtimeType&&other is LibraryItemExtras&&(identical(other.book, book) || other.book == book)&&(identical(other.heroTagSuffix, heroTagSuffix) || other.heroTagSuffix == heroTagSuffix));
|
||||
}
|
||||
|
||||
|
||||
@override
|
||||
int get hashCode => Object.hash(runtimeType,book,heroTagSuffix);
|
||||
|
||||
@override
|
||||
String toString() {
|
||||
return 'LibraryItemExtras(book: $book, heroTagSuffix: $heroTagSuffix)';
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
/// @nodoc
|
||||
abstract class $LibraryItemExtrasCopyWith<$Res> {
|
||||
factory $LibraryItemExtrasCopyWith(
|
||||
LibraryItemExtras value, $Res Function(LibraryItemExtras) then) =
|
||||
_$LibraryItemExtrasCopyWithImpl<$Res, LibraryItemExtras>;
|
||||
@useResult
|
||||
$Res call({BookMinified? book, String heroTagSuffix});
|
||||
}
|
||||
abstract mixin class $LibraryItemExtrasCopyWith<$Res> {
|
||||
factory $LibraryItemExtrasCopyWith(LibraryItemExtras value, $Res Function(LibraryItemExtras) _then) = _$LibraryItemExtrasCopyWithImpl;
|
||||
@useResult
|
||||
$Res call({
|
||||
BookMinified? book, String heroTagSuffix
|
||||
});
|
||||
|
||||
|
||||
|
||||
|
||||
}
|
||||
/// @nodoc
|
||||
class _$LibraryItemExtrasCopyWithImpl<$Res, $Val extends LibraryItemExtras>
|
||||
class _$LibraryItemExtrasCopyWithImpl<$Res>
|
||||
implements $LibraryItemExtrasCopyWith<$Res> {
|
||||
_$LibraryItemExtrasCopyWithImpl(this._value, this._then);
|
||||
_$LibraryItemExtrasCopyWithImpl(this._self, this._then);
|
||||
|
||||
// ignore: unused_field
|
||||
final $Val _value;
|
||||
// ignore: unused_field
|
||||
final $Res Function($Val) _then;
|
||||
final LibraryItemExtras _self;
|
||||
final $Res Function(LibraryItemExtras) _then;
|
||||
|
||||
/// Create a copy of LibraryItemExtras
|
||||
/// with the given fields replaced by the non-null parameter values.
|
||||
@pragma('vm:prefer-inline')
|
||||
@override
|
||||
$Res call({
|
||||
Object? book = freezed,
|
||||
Object? heroTagSuffix = null,
|
||||
}) {
|
||||
return _then(_value.copyWith(
|
||||
book: freezed == book
|
||||
? _value.book
|
||||
: book // ignore: cast_nullable_to_non_nullable
|
||||
as BookMinified?,
|
||||
heroTagSuffix: null == heroTagSuffix
|
||||
? _value.heroTagSuffix
|
||||
: heroTagSuffix // ignore: cast_nullable_to_non_nullable
|
||||
as String,
|
||||
) as $Val);
|
||||
}
|
||||
/// Create a copy of LibraryItemExtras
|
||||
/// with the given fields replaced by the non-null parameter values.
|
||||
@pragma('vm:prefer-inline') @override $Res call({Object? book = freezed,Object? heroTagSuffix = null,}) {
|
||||
return _then(_self.copyWith(
|
||||
book: freezed == book ? _self.book : book // ignore: cast_nullable_to_non_nullable
|
||||
as BookMinified?,heroTagSuffix: null == heroTagSuffix ? _self.heroTagSuffix : heroTagSuffix // ignore: cast_nullable_to_non_nullable
|
||||
as String,
|
||||
));
|
||||
}
|
||||
|
||||
/// @nodoc
|
||||
abstract class _$$LibraryItemExtrasImplCopyWith<$Res>
|
||||
implements $LibraryItemExtrasCopyWith<$Res> {
|
||||
factory _$$LibraryItemExtrasImplCopyWith(_$LibraryItemExtrasImpl value,
|
||||
$Res Function(_$LibraryItemExtrasImpl) then) =
|
||||
__$$LibraryItemExtrasImplCopyWithImpl<$Res>;
|
||||
@override
|
||||
@useResult
|
||||
$Res call({BookMinified? book, String heroTagSuffix});
|
||||
}
|
||||
|
||||
/// @nodoc
|
||||
class __$$LibraryItemExtrasImplCopyWithImpl<$Res>
|
||||
extends _$LibraryItemExtrasCopyWithImpl<$Res, _$LibraryItemExtrasImpl>
|
||||
implements _$$LibraryItemExtrasImplCopyWith<$Res> {
|
||||
__$$LibraryItemExtrasImplCopyWithImpl(_$LibraryItemExtrasImpl _value,
|
||||
$Res Function(_$LibraryItemExtrasImpl) _then)
|
||||
: super(_value, _then);
|
||||
|
||||
/// Create a copy of LibraryItemExtras
|
||||
/// with the given fields replaced by the non-null parameter values.
|
||||
@pragma('vm:prefer-inline')
|
||||
@override
|
||||
$Res call({
|
||||
Object? book = freezed,
|
||||
Object? heroTagSuffix = null,
|
||||
}) {
|
||||
return _then(_$LibraryItemExtrasImpl(
|
||||
book: freezed == book
|
||||
? _value.book
|
||||
: book // ignore: cast_nullable_to_non_nullable
|
||||
as BookMinified?,
|
||||
heroTagSuffix: null == heroTagSuffix
|
||||
? _value.heroTagSuffix
|
||||
: heroTagSuffix // ignore: cast_nullable_to_non_nullable
|
||||
as String,
|
||||
));
|
||||
}
|
||||
/// Adds pattern-matching-related methods to [LibraryItemExtras].
|
||||
extension LibraryItemExtrasPatterns on LibraryItemExtras {
|
||||
/// A variant of `map` that fallback to returning `orElse`.
|
||||
///
|
||||
/// It is equivalent to doing:
|
||||
/// ```dart
|
||||
/// switch (sealedClass) {
|
||||
/// case final Subclass value:
|
||||
/// return ...;
|
||||
/// case _:
|
||||
/// return orElse();
|
||||
/// }
|
||||
/// ```
|
||||
|
||||
@optionalTypeArgs TResult maybeMap<TResult extends Object?>(TResult Function( _LibraryItemExtras value)? $default,{required TResult orElse(),}){
|
||||
final _that = this;
|
||||
switch (_that) {
|
||||
case _LibraryItemExtras() when $default != null:
|
||||
return $default(_that);case _:
|
||||
return orElse();
|
||||
|
||||
}
|
||||
}
|
||||
/// A `switch`-like method, using callbacks.
|
||||
///
|
||||
/// Callbacks receives the raw object, upcasted.
|
||||
/// It is equivalent to doing:
|
||||
/// ```dart
|
||||
/// switch (sealedClass) {
|
||||
/// case final Subclass value:
|
||||
/// return ...;
|
||||
/// case final Subclass2 value:
|
||||
/// return ...;
|
||||
/// }
|
||||
/// ```
|
||||
|
||||
@optionalTypeArgs TResult map<TResult extends Object?>(TResult Function( _LibraryItemExtras value) $default,){
|
||||
final _that = this;
|
||||
switch (_that) {
|
||||
case _LibraryItemExtras():
|
||||
return $default(_that);}
|
||||
}
|
||||
/// A variant of `map` that fallback to returning `null`.
|
||||
///
|
||||
/// It is equivalent to doing:
|
||||
/// ```dart
|
||||
/// switch (sealedClass) {
|
||||
/// case final Subclass value:
|
||||
/// return ...;
|
||||
/// case _:
|
||||
/// return null;
|
||||
/// }
|
||||
/// ```
|
||||
|
||||
@optionalTypeArgs TResult? mapOrNull<TResult extends Object?>(TResult? Function( _LibraryItemExtras value)? $default,){
|
||||
final _that = this;
|
||||
switch (_that) {
|
||||
case _LibraryItemExtras() when $default != null:
|
||||
return $default(_that);case _:
|
||||
return null;
|
||||
|
||||
}
|
||||
}
|
||||
/// A variant of `when` that fallback to an `orElse` callback.
|
||||
///
|
||||
/// It is equivalent to doing:
|
||||
/// ```dart
|
||||
/// switch (sealedClass) {
|
||||
/// case Subclass(:final field):
|
||||
/// return ...;
|
||||
/// case _:
|
||||
/// return orElse();
|
||||
/// }
|
||||
/// ```
|
||||
|
||||
@optionalTypeArgs TResult maybeWhen<TResult extends Object?>(TResult Function( BookMinified? book, String heroTagSuffix)? $default,{required TResult orElse(),}) {final _that = this;
|
||||
switch (_that) {
|
||||
case _LibraryItemExtras() when $default != null:
|
||||
return $default(_that.book,_that.heroTagSuffix);case _:
|
||||
return orElse();
|
||||
|
||||
}
|
||||
}
|
||||
/// A `switch`-like method, using callbacks.
|
||||
///
|
||||
/// As opposed to `map`, this offers destructuring.
|
||||
/// It is equivalent to doing:
|
||||
/// ```dart
|
||||
/// switch (sealedClass) {
|
||||
/// case Subclass(:final field):
|
||||
/// return ...;
|
||||
/// case Subclass2(:final field2):
|
||||
/// return ...;
|
||||
/// }
|
||||
/// ```
|
||||
|
||||
@optionalTypeArgs TResult when<TResult extends Object?>(TResult Function( BookMinified? book, String heroTagSuffix) $default,) {final _that = this;
|
||||
switch (_that) {
|
||||
case _LibraryItemExtras():
|
||||
return $default(_that.book,_that.heroTagSuffix);}
|
||||
}
|
||||
/// A variant of `when` that fallback to returning `null`
|
||||
///
|
||||
/// It is equivalent to doing:
|
||||
/// ```dart
|
||||
/// switch (sealedClass) {
|
||||
/// case Subclass(:final field):
|
||||
/// return ...;
|
||||
/// case _:
|
||||
/// return null;
|
||||
/// }
|
||||
/// ```
|
||||
|
||||
@optionalTypeArgs TResult? whenOrNull<TResult extends Object?>(TResult? Function( BookMinified? book, String heroTagSuffix)? $default,) {final _that = this;
|
||||
switch (_that) {
|
||||
case _LibraryItemExtras() when $default != null:
|
||||
return $default(_that.book,_that.heroTagSuffix);case _:
|
||||
return null;
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
/// @nodoc
|
||||
|
||||
class _$LibraryItemExtrasImpl implements _LibraryItemExtras {
|
||||
const _$LibraryItemExtrasImpl({this.book, this.heroTagSuffix = ''});
|
||||
|
||||
@override
|
||||
final BookMinified? book;
|
||||
@override
|
||||
@JsonKey()
|
||||
final String heroTagSuffix;
|
||||
class _LibraryItemExtras implements LibraryItemExtras {
|
||||
const _LibraryItemExtras({this.book, this.heroTagSuffix = ''});
|
||||
|
||||
|
||||
@override
|
||||
String toString() {
|
||||
return 'LibraryItemExtras(book: $book, heroTagSuffix: $heroTagSuffix)';
|
||||
}
|
||||
@override final BookMinified? book;
|
||||
@override@JsonKey() final String heroTagSuffix;
|
||||
|
||||
@override
|
||||
bool operator ==(Object other) {
|
||||
return identical(this, other) ||
|
||||
(other.runtimeType == runtimeType &&
|
||||
other is _$LibraryItemExtrasImpl &&
|
||||
(identical(other.book, book) || other.book == book) &&
|
||||
(identical(other.heroTagSuffix, heroTagSuffix) ||
|
||||
other.heroTagSuffix == heroTagSuffix));
|
||||
}
|
||||
/// Create a copy of LibraryItemExtras
|
||||
/// with the given fields replaced by the non-null parameter values.
|
||||
@override @JsonKey(includeFromJson: false, includeToJson: false)
|
||||
@pragma('vm:prefer-inline')
|
||||
_$LibraryItemExtrasCopyWith<_LibraryItemExtras> get copyWith => __$LibraryItemExtrasCopyWithImpl<_LibraryItemExtras>(this, _$identity);
|
||||
|
||||
@override
|
||||
int get hashCode => Object.hash(runtimeType, book, heroTagSuffix);
|
||||
|
||||
/// Create a copy of LibraryItemExtras
|
||||
/// with the given fields replaced by the non-null parameter values.
|
||||
@JsonKey(includeFromJson: false, includeToJson: false)
|
||||
@override
|
||||
@pragma('vm:prefer-inline')
|
||||
_$$LibraryItemExtrasImplCopyWith<_$LibraryItemExtrasImpl> get copyWith =>
|
||||
__$$LibraryItemExtrasImplCopyWithImpl<_$LibraryItemExtrasImpl>(
|
||||
this, _$identity);
|
||||
|
||||
@override
|
||||
bool operator ==(Object other) {
|
||||
return identical(this, other) || (other.runtimeType == runtimeType&&other is _LibraryItemExtras&&(identical(other.book, book) || other.book == book)&&(identical(other.heroTagSuffix, heroTagSuffix) || other.heroTagSuffix == heroTagSuffix));
|
||||
}
|
||||
|
||||
abstract class _LibraryItemExtras implements LibraryItemExtras {
|
||||
const factory _LibraryItemExtras(
|
||||
{final BookMinified? book,
|
||||
final String heroTagSuffix}) = _$LibraryItemExtrasImpl;
|
||||
|
||||
@override
|
||||
BookMinified? get book;
|
||||
@override
|
||||
String get heroTagSuffix;
|
||||
@override
|
||||
int get hashCode => Object.hash(runtimeType,book,heroTagSuffix);
|
||||
|
||||
/// Create a copy of LibraryItemExtras
|
||||
/// with the given fields replaced by the non-null parameter values.
|
||||
@override
|
||||
@JsonKey(includeFromJson: false, includeToJson: false)
|
||||
_$$LibraryItemExtrasImplCopyWith<_$LibraryItemExtrasImpl> get copyWith =>
|
||||
throw _privateConstructorUsedError;
|
||||
@override
|
||||
String toString() {
|
||||
return 'LibraryItemExtras(book: $book, heroTagSuffix: $heroTagSuffix)';
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
/// @nodoc
|
||||
abstract mixin class _$LibraryItemExtrasCopyWith<$Res> implements $LibraryItemExtrasCopyWith<$Res> {
|
||||
factory _$LibraryItemExtrasCopyWith(_LibraryItemExtras value, $Res Function(_LibraryItemExtras) _then) = __$LibraryItemExtrasCopyWithImpl;
|
||||
@override @useResult
|
||||
$Res call({
|
||||
BookMinified? book, String heroTagSuffix
|
||||
});
|
||||
|
||||
|
||||
|
||||
|
||||
}
|
||||
/// @nodoc
|
||||
class __$LibraryItemExtrasCopyWithImpl<$Res>
|
||||
implements _$LibraryItemExtrasCopyWith<$Res> {
|
||||
__$LibraryItemExtrasCopyWithImpl(this._self, this._then);
|
||||
|
||||
final _LibraryItemExtras _self;
|
||||
final $Res Function(_LibraryItemExtras) _then;
|
||||
|
||||
/// Create a copy of LibraryItemExtras
|
||||
/// with the given fields replaced by the non-null parameter values.
|
||||
@override @pragma('vm:prefer-inline') $Res call({Object? book = freezed,Object? heroTagSuffix = null,}) {
|
||||
return _then(_LibraryItemExtras(
|
||||
book: freezed == book ? _self.book : book // ignore: cast_nullable_to_non_nullable
|
||||
as BookMinified?,heroTagSuffix: null == heroTagSuffix ? _self.heroTagSuffix : heroTagSuffix // ignore: cast_nullable_to_non_nullable
|
||||
as String,
|
||||
));
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
// dart format on
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue