Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ギャラリー関連のエンドポイントに対応 #57

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 14 additions & 0 deletions lib/misskey_dart.dart
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,7 @@ export 'src/data/antennas/antennas_update_request.dart';
export 'src/data/ap/ap_show_request.dart';
export 'src/data/ap/ap_show_response.dart';
export 'src/data/base/blocking.dart';
export 'src/data/base/gallery_post.dart';
export 'src/data/base/muting.dart';
export 'src/data/base/note.dart';
export 'src/data/base/renote_muting.dart';
Expand Down Expand Up @@ -118,6 +119,14 @@ export 'src/data/flash/flash_my_request.dart';
export 'src/data/flash/flash_show_request.dart';
export 'src/data/flash/flash_unlike_request.dart';
export 'src/data/flash/flash_update_request.dart';
export 'src/data/gallery/gallery_featured_request.dart';
export 'src/data/gallery/gallery_posts_request.dart';
export 'src/data/gallery/posts/gallery_posts_create_request.dart';
export 'src/data/gallery/posts/gallery_posts_delete_request.dart';
export 'src/data/gallery/posts/gallery_posts_like_request.dart';
export 'src/data/gallery/posts/gallery_posts_show_request.dart';
export 'src/data/gallery/posts/gallery_posts_unlike_request.dart';
export 'src/data/gallery/posts/gallery_posts_update_request.dart';
export 'src/data/i/i_notifications_request.dart';
export 'src/data/i/i_notifications_response.dart';
export 'src/data/i/i_favorites_request.dart';
Expand All @@ -129,6 +138,9 @@ export 'src/data/i/i_pin_request.dart';
export 'src/data/i/i_unpin_request.dart';
export 'src/data/i/i_update_request.dart';
export 'src/data/i/i_read_announcement_request.dart';
export 'src/data/i/gallery/i_gallery_likes_request.dart';
export 'src/data/i/gallery/i_gallery_likes_response.dart';
export 'src/data/i/gallery/i_gallery_posts_request.dart';
export 'src/data/i/registry/i_registry_get_all_request.dart';
export 'src/data/i/registry/i_registry_get_detail_request.dart';
export 'src/data/i/registry/i_registry_get_detail_response.dart';
Expand Down Expand Up @@ -194,6 +206,7 @@ export 'src/data/users/lists/users_lists_show_request.dart';
export 'src/data/users/lists/users_lists_show_response.dart';
export 'src/data/users/lists/users_lists_unfavorite_request.dart';
export 'src/data/users/lists/users_lists_update_request.dart';
export 'src/data/users/gallery/users_gallery_posts_request.dart';
export 'src/data/users/users_report_abuse_request.dart';
export 'src/data/users/users_reactions_request.dart';
export 'src/data/users/users_reactions_response.dart';
Expand Down Expand Up @@ -247,6 +260,7 @@ export 'src/misskey_clips.dart';
export 'src/misskey_drive.dart';
export 'src/misskey_federation.dart';
export 'src/misskey_following.dart';
export 'src/misskey_gallery.dart';
export 'src/misskey_hashtags.dart';
export 'src/misskey_i.dart';
export 'src/misskey_mute.dart';
Expand Down
27 changes: 27 additions & 0 deletions lib/src/data/base/gallery_post.dart
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
import 'package:freezed_annotation/freezed_annotation.dart';
import 'package:misskey_dart/misskey_dart.dart';

part 'gallery_post.freezed.dart';
part 'gallery_post.g.dart';

@freezed
class GalleryPost with _$GalleryPost {
const factory GalleryPost({
required String id,
required DateTime createdAt,
required DateTime updatedAt,
required String userId,
required UserLite user,
required String title,
String? description,
required List<String> fileIds,
required List<DriveFile> files,
List<String>? tags,
required bool isSensitive,
required int likedCount,
bool? isLiked,
}) = _GalleryPost;

factory GalleryPost.fromJson(Map<String, Object?> json) =>
_$GalleryPostFromJson(json);
}
Loading
Loading