Skip to content

Commit

Permalink
fix: ローカルのみを入れられるように
Browse files Browse the repository at this point in the history
  • Loading branch information
shiosyakeyakini-info committed Oct 19, 2023
1 parent 284d011 commit 486139d
Show file tree
Hide file tree
Showing 6 changed files with 809 additions and 767 deletions.
2 changes: 2 additions & 0 deletions lib/model/antenna_settings.dart
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ class AntennaSettings with _$AntennaSettings {
@Default(false) bool withReplies,
@Default(false) bool withFile,
@Default(false) bool notify,
@Default(false) bool localOnly,
}) = _AntennaSettings;
const AntennaSettings._();

Expand All @@ -31,6 +32,7 @@ class AntennaSettings with _$AntennaSettings {
withReplies: antenna.withReplies,
withFile: antenna.withFile,
notify: antenna.notify,
localOnly: antenna.localOnly ?? false,
);
}
}
37 changes: 30 additions & 7 deletions lib/model/antenna_settings.freezed.dart
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@ mixin _$AntennaSettings {
bool get withReplies => throw _privateConstructorUsedError;
bool get withFile => throw _privateConstructorUsedError;
bool get notify => throw _privateConstructorUsedError;
bool get localOnly => throw _privateConstructorUsedError;

@JsonKey(ignore: true)
$AntennaSettingsCopyWith<AntennaSettings> get copyWith =>
Expand All @@ -48,7 +49,8 @@ abstract class $AntennaSettingsCopyWith<$Res> {
bool caseSensitive,
bool withReplies,
bool withFile,
bool notify});
bool notify,
bool localOnly});
}

/// @nodoc
Expand All @@ -74,6 +76,7 @@ class _$AntennaSettingsCopyWithImpl<$Res, $Val extends AntennaSettings>
Object? withReplies = null,
Object? withFile = null,
Object? notify = null,
Object? localOnly = null,
}) {
return _then(_value.copyWith(
name: null == name
Expand Down Expand Up @@ -116,6 +119,10 @@ class _$AntennaSettingsCopyWithImpl<$Res, $Val extends AntennaSettings>
? _value.notify
: notify // ignore: cast_nullable_to_non_nullable
as bool,
localOnly: null == localOnly
? _value.localOnly
: localOnly // ignore: cast_nullable_to_non_nullable
as bool,
) as $Val);
}
}
Expand All @@ -138,7 +145,8 @@ abstract class _$$_AntennaSettingsCopyWith<$Res>
bool caseSensitive,
bool withReplies,
bool withFile,
bool notify});
bool notify,
bool localOnly});
}

/// @nodoc
Expand All @@ -162,6 +170,7 @@ class __$$_AntennaSettingsCopyWithImpl<$Res>
Object? withReplies = null,
Object? withFile = null,
Object? notify = null,
Object? localOnly = null,
}) {
return _then(_$_AntennaSettings(
name: null == name
Expand Down Expand Up @@ -204,6 +213,10 @@ class __$$_AntennaSettingsCopyWithImpl<$Res>
? _value.notify
: notify // ignore: cast_nullable_to_non_nullable
as bool,
localOnly: null == localOnly
? _value.localOnly
: localOnly // ignore: cast_nullable_to_non_nullable
as bool,
));
}
}
Expand All @@ -221,7 +234,8 @@ class _$_AntennaSettings extends _AntennaSettings {
this.caseSensitive = false,
this.withReplies = false,
this.withFile = false,
this.notify = false})
this.notify = false,
this.localOnly = false})
: _keywords = keywords,
_excludeKeywords = excludeKeywords,
_users = users,
Expand Down Expand Up @@ -274,10 +288,13 @@ class _$_AntennaSettings extends _AntennaSettings {
@override
@JsonKey()
final bool notify;
@override
@JsonKey()
final bool localOnly;

@override
String toString() {
return 'AntennaSettings(name: $name, src: $src, userListId: $userListId, keywords: $keywords, excludeKeywords: $excludeKeywords, users: $users, caseSensitive: $caseSensitive, withReplies: $withReplies, withFile: $withFile, notify: $notify)';
return 'AntennaSettings(name: $name, src: $src, userListId: $userListId, keywords: $keywords, excludeKeywords: $excludeKeywords, users: $users, caseSensitive: $caseSensitive, withReplies: $withReplies, withFile: $withFile, notify: $notify, localOnly: $localOnly)';
}

@override
Expand All @@ -299,7 +316,9 @@ class _$_AntennaSettings extends _AntennaSettings {
other.withReplies == withReplies) &&
(identical(other.withFile, withFile) ||
other.withFile == withFile) &&
(identical(other.notify, notify) || other.notify == notify));
(identical(other.notify, notify) || other.notify == notify) &&
(identical(other.localOnly, localOnly) ||
other.localOnly == localOnly));
}

@override
Expand All @@ -314,7 +333,8 @@ class _$_AntennaSettings extends _AntennaSettings {
caseSensitive,
withReplies,
withFile,
notify);
notify,
localOnly);

@JsonKey(ignore: true)
@override
Expand All @@ -334,7 +354,8 @@ abstract class _AntennaSettings extends AntennaSettings {
final bool caseSensitive,
final bool withReplies,
final bool withFile,
final bool notify}) = _$_AntennaSettings;
final bool notify,
final bool localOnly}) = _$_AntennaSettings;
const _AntennaSettings._() : super._();

@override
Expand All @@ -358,6 +379,8 @@ abstract class _AntennaSettings extends AntennaSettings {
@override
bool get notify;
@override
bool get localOnly;
@override
@JsonKey(ignore: true)
_$$_AntennaSettingsCopyWith<_$_AntennaSettings> get copyWith =>
throw _privateConstructorUsedError;
Expand Down
Loading

0 comments on commit 486139d

Please sign in to comment.