Skip to content

Commit

Permalink
update to Misskey 2023.12.0
Browse files Browse the repository at this point in the history
  • Loading branch information
shiosyakeyakini-info committed Dec 3, 2023
1 parent 0516cfc commit 0e82975
Show file tree
Hide file tree
Showing 30 changed files with 490 additions and 77 deletions.
1 change: 1 addition & 0 deletions lib/src/data/channels/channels_timeline_request.dart
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ class ChannelsTimelineRequest with _$ChannelsTimelineRequest {
String? untilId,
@EpocTimeDateTimeConverter.withMilliSeconds() DateTime? sinceDate,
@EpocTimeDateTimeConverter.withMilliSeconds() DateTime? untilDate,
bool? allowPartial,
}) = _ChannelsTimelineRequest;

factory ChannelsTimelineRequest.fromJson(Map<String, Object?> json) =>
Expand Down
38 changes: 29 additions & 9 deletions lib/src/data/channels/channels_timeline_request.freezed.dart
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,7 @@ mixin _$ChannelsTimelineRequest {
DateTime? get sinceDate => throw _privateConstructorUsedError;
@EpocTimeDateTimeConverter.withMilliSeconds()
DateTime? get untilDate => throw _privateConstructorUsedError;
bool? get allowPartial => throw _privateConstructorUsedError;

Map<String, dynamic> toJson() => throw _privateConstructorUsedError;
@JsonKey(ignore: true)
Expand All @@ -49,7 +50,8 @@ abstract class $ChannelsTimelineRequestCopyWith<$Res> {
String? sinceId,
String? untilId,
@EpocTimeDateTimeConverter.withMilliSeconds() DateTime? sinceDate,
@EpocTimeDateTimeConverter.withMilliSeconds() DateTime? untilDate});
@EpocTimeDateTimeConverter.withMilliSeconds() DateTime? untilDate,
bool? allowPartial});
}

/// @nodoc
Expand All @@ -72,6 +74,7 @@ class _$ChannelsTimelineRequestCopyWithImpl<$Res,
Object? untilId = freezed,
Object? sinceDate = freezed,
Object? untilDate = freezed,
Object? allowPartial = freezed,
}) {
return _then(_value.copyWith(
channelId: null == channelId
Expand All @@ -98,6 +101,10 @@ class _$ChannelsTimelineRequestCopyWithImpl<$Res,
? _value.untilDate
: untilDate // ignore: cast_nullable_to_non_nullable
as DateTime?,
allowPartial: freezed == allowPartial
? _value.allowPartial
: allowPartial // ignore: cast_nullable_to_non_nullable
as bool?,
) as $Val);
}
}
Expand All @@ -117,7 +124,8 @@ abstract class _$$ChannelsTimelineRequestImplCopyWith<$Res>
String? sinceId,
String? untilId,
@EpocTimeDateTimeConverter.withMilliSeconds() DateTime? sinceDate,
@EpocTimeDateTimeConverter.withMilliSeconds() DateTime? untilDate});
@EpocTimeDateTimeConverter.withMilliSeconds() DateTime? untilDate,
bool? allowPartial});
}

/// @nodoc
Expand All @@ -139,6 +147,7 @@ class __$$ChannelsTimelineRequestImplCopyWithImpl<$Res>
Object? untilId = freezed,
Object? sinceDate = freezed,
Object? untilDate = freezed,
Object? allowPartial = freezed,
}) {
return _then(_$ChannelsTimelineRequestImpl(
channelId: null == channelId
Expand All @@ -165,6 +174,10 @@ class __$$ChannelsTimelineRequestImplCopyWithImpl<$Res>
? _value.untilDate
: untilDate // ignore: cast_nullable_to_non_nullable
as DateTime?,
allowPartial: freezed == allowPartial
? _value.allowPartial
: allowPartial // ignore: cast_nullable_to_non_nullable
as bool?,
));
}
}
Expand All @@ -178,7 +191,8 @@ class _$ChannelsTimelineRequestImpl implements _ChannelsTimelineRequest {
this.sinceId,
this.untilId,
@EpocTimeDateTimeConverter.withMilliSeconds() this.sinceDate,
@EpocTimeDateTimeConverter.withMilliSeconds() this.untilDate});
@EpocTimeDateTimeConverter.withMilliSeconds() this.untilDate,
this.allowPartial});

factory _$ChannelsTimelineRequestImpl.fromJson(Map<String, dynamic> json) =>
_$$ChannelsTimelineRequestImplFromJson(json);
Expand All @@ -198,10 +212,12 @@ class _$ChannelsTimelineRequestImpl implements _ChannelsTimelineRequest {
@override
@EpocTimeDateTimeConverter.withMilliSeconds()
final DateTime? untilDate;
@override
final bool? allowPartial;

@override
String toString() {
return 'ChannelsTimelineRequest(channelId: $channelId, limit: $limit, sinceId: $sinceId, untilId: $untilId, sinceDate: $sinceDate, untilDate: $untilDate)';
return 'ChannelsTimelineRequest(channelId: $channelId, limit: $limit, sinceId: $sinceId, untilId: $untilId, sinceDate: $sinceDate, untilDate: $untilDate, allowPartial: $allowPartial)';
}

@override
Expand All @@ -217,13 +233,15 @@ class _$ChannelsTimelineRequestImpl implements _ChannelsTimelineRequest {
(identical(other.sinceDate, sinceDate) ||
other.sinceDate == sinceDate) &&
(identical(other.untilDate, untilDate) ||
other.untilDate == untilDate));
other.untilDate == untilDate) &&
(identical(other.allowPartial, allowPartial) ||
other.allowPartial == allowPartial));
}

@JsonKey(ignore: true)
@override
int get hashCode => Object.hash(
runtimeType, channelId, limit, sinceId, untilId, sinceDate, untilDate);
int get hashCode => Object.hash(runtimeType, channelId, limit, sinceId,
untilId, sinceDate, untilDate, allowPartial);

@JsonKey(ignore: true)
@override
Expand All @@ -247,8 +265,8 @@ abstract class _ChannelsTimelineRequest implements ChannelsTimelineRequest {
final String? sinceId,
final String? untilId,
@EpocTimeDateTimeConverter.withMilliSeconds() final DateTime? sinceDate,
@EpocTimeDateTimeConverter.withMilliSeconds()
final DateTime? untilDate}) = _$ChannelsTimelineRequestImpl;
@EpocTimeDateTimeConverter.withMilliSeconds() final DateTime? untilDate,
final bool? allowPartial}) = _$ChannelsTimelineRequestImpl;

factory _ChannelsTimelineRequest.fromJson(Map<String, dynamic> json) =
_$ChannelsTimelineRequestImpl.fromJson;
Expand All @@ -269,6 +287,8 @@ abstract class _ChannelsTimelineRequest implements ChannelsTimelineRequest {
@EpocTimeDateTimeConverter.withMilliSeconds()
DateTime? get untilDate;
@override
bool? get allowPartial;
@override
@JsonKey(ignore: true)
_$$ChannelsTimelineRequestImplCopyWith<_$ChannelsTimelineRequestImpl>
get copyWith => throw _privateConstructorUsedError;
Expand Down
2 changes: 2 additions & 0 deletions lib/src/data/channels/channels_timeline_request.g.dart

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions lib/src/data/i/i_update_request.dart
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,7 @@ class IUpdateRequest with _$IUpdateRequest {
String? pinnedPageId,
List<String>? mutingNotificationTypes,
@MuteWordsConverter() List<MuteWord>? mutedWords,
@MuteWordsConverter() List<MuteWord>? hardMutedWords,
List<String>? mutedInstances,
List<String>? emailNotificationTypes,
List<String>? alsoKnownAs,
Expand Down
36 changes: 35 additions & 1 deletion lib/src/data/i/i_update_request.freezed.dart
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,8 @@ mixin _$IUpdateRequest {
throw _privateConstructorUsedError;
@MuteWordsConverter()
List<MuteWord>? get mutedWords => throw _privateConstructorUsedError;
@MuteWordsConverter()
List<MuteWord>? get hardMutedWords => throw _privateConstructorUsedError;
List<String>? get mutedInstances => throw _privateConstructorUsedError;
List<String>? get emailNotificationTypes =>
throw _privateConstructorUsedError;
Expand Down Expand Up @@ -91,6 +93,7 @@ abstract class $IUpdateRequestCopyWith<$Res> {
String? pinnedPageId,
List<String>? mutingNotificationTypes,
@MuteWordsConverter() List<MuteWord>? mutedWords,
@MuteWordsConverter() List<MuteWord>? hardMutedWords,
List<String>? mutedInstances,
List<String>? emailNotificationTypes,
List<String>? alsoKnownAs});
Expand Down Expand Up @@ -134,6 +137,7 @@ class _$IUpdateRequestCopyWithImpl<$Res, $Val extends IUpdateRequest>
Object? pinnedPageId = freezed,
Object? mutingNotificationTypes = freezed,
Object? mutedWords = freezed,
Object? hardMutedWords = freezed,
Object? mutedInstances = freezed,
Object? emailNotificationTypes = freezed,
Object? alsoKnownAs = freezed,
Expand Down Expand Up @@ -239,6 +243,10 @@ class _$IUpdateRequestCopyWithImpl<$Res, $Val extends IUpdateRequest>
? _value.mutedWords
: mutedWords // ignore: cast_nullable_to_non_nullable
as List<MuteWord>?,
hardMutedWords: freezed == hardMutedWords
? _value.hardMutedWords
: hardMutedWords // ignore: cast_nullable_to_non_nullable
as List<MuteWord>?,
mutedInstances: freezed == mutedInstances
? _value.mutedInstances
: mutedInstances // ignore: cast_nullable_to_non_nullable
Expand Down Expand Up @@ -289,6 +297,7 @@ abstract class _$$IUpdateRequestImplCopyWith<$Res>
String? pinnedPageId,
List<String>? mutingNotificationTypes,
@MuteWordsConverter() List<MuteWord>? mutedWords,
@MuteWordsConverter() List<MuteWord>? hardMutedWords,
List<String>? mutedInstances,
List<String>? emailNotificationTypes,
List<String>? alsoKnownAs});
Expand Down Expand Up @@ -330,6 +339,7 @@ class __$$IUpdateRequestImplCopyWithImpl<$Res>
Object? pinnedPageId = freezed,
Object? mutingNotificationTypes = freezed,
Object? mutedWords = freezed,
Object? hardMutedWords = freezed,
Object? mutedInstances = freezed,
Object? emailNotificationTypes = freezed,
Object? alsoKnownAs = freezed,
Expand Down Expand Up @@ -432,6 +442,10 @@ class __$$IUpdateRequestImplCopyWithImpl<$Res>
? _value._mutedWords
: mutedWords // ignore: cast_nullable_to_non_nullable
as List<MuteWord>?,
hardMutedWords: freezed == hardMutedWords
? _value._hardMutedWords
: hardMutedWords // ignore: cast_nullable_to_non_nullable
as List<MuteWord>?,
mutedInstances: freezed == mutedInstances
? _value._mutedInstances
: mutedInstances // ignore: cast_nullable_to_non_nullable
Expand Down Expand Up @@ -477,12 +491,14 @@ class _$IUpdateRequestImpl implements _IUpdateRequest {
this.pinnedPageId,
final List<String>? mutingNotificationTypes,
@MuteWordsConverter() final List<MuteWord>? mutedWords,
@MuteWordsConverter() final List<MuteWord>? hardMutedWords,
final List<String>? mutedInstances,
final List<String>? emailNotificationTypes,
final List<String>? alsoKnownAs})
: _fields = fields,
_mutingNotificationTypes = mutingNotificationTypes,
_mutedWords = mutedWords,
_hardMutedWords = hardMutedWords,
_mutedInstances = mutedInstances,
_emailNotificationTypes = emailNotificationTypes,
_alsoKnownAs = alsoKnownAs;
Expand Down Expand Up @@ -567,6 +583,17 @@ class _$IUpdateRequestImpl implements _IUpdateRequest {
return EqualUnmodifiableListView(value);
}

final List<MuteWord>? _hardMutedWords;
@override
@MuteWordsConverter()
List<MuteWord>? get hardMutedWords {
final value = _hardMutedWords;
if (value == null) return null;
if (_hardMutedWords is EqualUnmodifiableListView) return _hardMutedWords;
// ignore: implicit_dynamic_type
return EqualUnmodifiableListView(value);
}

final List<String>? _mutedInstances;
@override
List<String>? get mutedInstances {
Expand Down Expand Up @@ -600,7 +627,7 @@ class _$IUpdateRequestImpl implements _IUpdateRequest {

@override
String toString() {
return 'IUpdateRequest(name: $name, description: $description, location: $location, birthday: $birthday, lang: $lang, avatarId: $avatarId, bannerId: $bannerId, fields: $fields, isLocked: $isLocked, isExplorable: $isExplorable, hideOnlineStatus: $hideOnlineStatus, publicReactions: $publicReactions, carefulBot: $carefulBot, autoAcceptFollowed: $autoAcceptFollowed, noCrawle: $noCrawle, preventAiLearning: $preventAiLearning, isBot: $isBot, isCat: $isCat, injectFeaturedNote: $injectFeaturedNote, receiveAnnouncementEmail: $receiveAnnouncementEmail, alwaysMarkNsfw: $alwaysMarkNsfw, ffVisibility: $ffVisibility, pinnedPageId: $pinnedPageId, mutingNotificationTypes: $mutingNotificationTypes, mutedWords: $mutedWords, mutedInstances: $mutedInstances, emailNotificationTypes: $emailNotificationTypes, alsoKnownAs: $alsoKnownAs)';
return 'IUpdateRequest(name: $name, description: $description, location: $location, birthday: $birthday, lang: $lang, avatarId: $avatarId, bannerId: $bannerId, fields: $fields, isLocked: $isLocked, isExplorable: $isExplorable, hideOnlineStatus: $hideOnlineStatus, publicReactions: $publicReactions, carefulBot: $carefulBot, autoAcceptFollowed: $autoAcceptFollowed, noCrawle: $noCrawle, preventAiLearning: $preventAiLearning, isBot: $isBot, isCat: $isCat, injectFeaturedNote: $injectFeaturedNote, receiveAnnouncementEmail: $receiveAnnouncementEmail, alwaysMarkNsfw: $alwaysMarkNsfw, ffVisibility: $ffVisibility, pinnedPageId: $pinnedPageId, mutingNotificationTypes: $mutingNotificationTypes, mutedWords: $mutedWords, hardMutedWords: $hardMutedWords, mutedInstances: $mutedInstances, emailNotificationTypes: $emailNotificationTypes, alsoKnownAs: $alsoKnownAs)';
}

@override
Expand Down Expand Up @@ -653,6 +680,8 @@ class _$IUpdateRequestImpl implements _IUpdateRequest {
other._mutingNotificationTypes, _mutingNotificationTypes) &&
const DeepCollectionEquality()
.equals(other._mutedWords, _mutedWords) &&
const DeepCollectionEquality()
.equals(other._hardMutedWords, _hardMutedWords) &&
const DeepCollectionEquality()
.equals(other._mutedInstances, _mutedInstances) &&
const DeepCollectionEquality().equals(
Expand Down Expand Up @@ -690,6 +719,7 @@ class _$IUpdateRequestImpl implements _IUpdateRequest {
pinnedPageId,
const DeepCollectionEquality().hash(_mutingNotificationTypes),
const DeepCollectionEquality().hash(_mutedWords),
const DeepCollectionEquality().hash(_hardMutedWords),
const DeepCollectionEquality().hash(_mutedInstances),
const DeepCollectionEquality().hash(_emailNotificationTypes),
const DeepCollectionEquality().hash(_alsoKnownAs)
Expand Down Expand Up @@ -737,6 +767,7 @@ abstract class _IUpdateRequest implements IUpdateRequest {
final String? pinnedPageId,
final List<String>? mutingNotificationTypes,
@MuteWordsConverter() final List<MuteWord>? mutedWords,
@MuteWordsConverter() final List<MuteWord>? hardMutedWords,
final List<String>? mutedInstances,
final List<String>? emailNotificationTypes,
final List<String>? alsoKnownAs}) = _$IUpdateRequestImpl;
Expand Down Expand Up @@ -797,6 +828,9 @@ abstract class _IUpdateRequest implements IUpdateRequest {
@MuteWordsConverter()
List<MuteWord>? get mutedWords;
@override
@MuteWordsConverter()
List<MuteWord>? get hardMutedWords;
@override
List<String>? get mutedInstances;
@override
List<String>? get emailNotificationTypes;
Expand Down
6 changes: 6 additions & 0 deletions lib/src/data/i/i_update_request.g.dart

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions lib/src/data/i_response.dart
Original file line number Diff line number Diff line change
Expand Up @@ -73,6 +73,7 @@ class IResponse with _$IResponse {
int? unreadNotificationsCount,
@Default([]) List<AnnouncementsResponse> unreadAnnouncements,
@MuteWordsConverter() required List<MuteWord> mutedWords,
@MuteWordsConverter() @Default([]) List<MuteWord> hardMutedWords,
required List<String> mutedInstances,
@Deprecated("Depracted from Misskey 2023.9.2")
List<String>? mutingNotificationTypes,
Expand Down
Loading

0 comments on commit 0e82975

Please sign in to comment.