lemmy-js-client 0.17.0-rc.10 → 0.17.0-rc.13
Sign up to get free protection for your applications and to get access to all the features.
package/dist/http.d.ts
CHANGED
@@ -1,5 +1,5 @@
|
|
1
1
|
import { CommentReportResponse, CommentResponse, CreateComment, CreateCommentLike, CreateCommentReport, DeleteComment, EditComment, GetComments, GetCommentsResponse, ListCommentReports, ListCommentReportsResponse, MarkCommentAsRead, RemoveComment, ResolveCommentReport, SaveComment } from "./interfaces/api/comment";
|
2
|
-
import { AddModToCommunity, AddModToCommunityResponse, BanFromCommunity, BanFromCommunityResponse, BlockCommunity, BlockCommunityResponse, CommunityResponse, CreateCommunity, DeleteCommunity, EditCommunity, FollowCommunity,
|
2
|
+
import { AddModToCommunity, AddModToCommunityResponse, BanFromCommunity, BanFromCommunityResponse, BlockCommunity, BlockCommunityResponse, CommunityResponse, CreateCommunity, DeleteCommunity, EditCommunity, FollowCommunity, GetCommunity, GetCommunityResponse, ListCommunities, ListCommunitiesResponse, RemoveCommunity, TransferCommunity } from "./interfaces/api/community";
|
3
3
|
import { AddAdmin, AddAdminResponse, BannedPersonsResponse, BanPerson, BanPersonResponse, BlockPerson, BlockPersonResponse, ChangePassword, CreatePrivateMessage, DeleteAccount, DeleteAccountResponse, DeletePrivateMessage, EditPrivateMessage, GetBannedPersons, GetCaptchaResponse, GetPersonDetails, GetPersonDetailsResponse, GetPersonMentions, GetPersonMentionsResponse, GetPrivateMessages, GetReplies, GetRepliesResponse, GetReportCount, GetReportCountResponse, GetUnreadCount, GetUnreadCountResponse, Login, LoginResponse, MarkAllAsRead, MarkPersonMentionAsRead, MarkPrivateMessageAsRead, PasswordChange, PasswordReset, PasswordResetResponse, PersonMentionResponse, PrivateMessageResponse, PrivateMessagesResponse, Register, SaveUserSettings, VerifyEmail, VerifyEmailResponse } from "./interfaces/api/person";
|
4
4
|
import { CreatePost, CreatePostLike, CreatePostReport, DeletePost, EditPost, GetPost, GetPostResponse, GetPosts, GetPostsResponse, GetSiteMetadata, GetSiteMetadataResponse, ListPostReports, ListPostReportsResponse, LockPost, MarkPostAsRead, PostReportResponse, PostResponse, RemovePost, ResolvePostReport, SavePost, StickyPost } from "./interfaces/api/post";
|
5
5
|
import { ApproveRegistrationApplication, CreateSite, EditSite, GetModlog, GetModlogResponse, GetSite, GetSiteConfig, GetSiteConfigResponse, GetSiteResponse, GetUnreadRegistrationApplicationCount, GetUnreadRegistrationApplicationCountResponse, LeaveAdmin, ListRegistrationApplications, ListRegistrationApplicationsResponse, RegistrationApplicationResponse, ResolveObject, ResolveObjectResponse, SaveSiteConfig, Search, SearchResponse, SiteResponse } from "./interfaces/api/site";
|
@@ -86,7 +86,7 @@ export declare class LemmyHttp {
|
|
86
86
|
* Follow / subscribe to a community.
|
87
87
|
* `HTTP.POST /community/follow`
|
88
88
|
*/
|
89
|
-
followCommunity(form: FollowCommunity): Promise<
|
89
|
+
followCommunity(form: FollowCommunity): Promise<CommunityResponse>;
|
90
90
|
/**
|
91
91
|
* Block a community.
|
92
92
|
* `HTTP.POST /community/block`
|
@@ -1,6 +1,6 @@
|
|
1
1
|
import { ListingType, SortType } from "../others";
|
2
2
|
import { Site } from "../source";
|
3
|
-
import {
|
3
|
+
import { CommunityModeratorView, CommunityView, PersonViewSafe } from "../views";
|
4
4
|
/**
|
5
5
|
* You can use either `id` or `name` as an id.
|
6
6
|
*
|
@@ -30,12 +30,6 @@ export interface CreateCommunity {
|
|
30
30
|
export interface CommunityResponse {
|
31
31
|
community_view: CommunityView;
|
32
32
|
}
|
33
|
-
export interface FollowCommunityResponse {
|
34
|
-
/**
|
35
|
-
* An unfollow returns null.
|
36
|
-
*/
|
37
|
-
community_follower_view?: CommunityFollowerView;
|
38
|
-
}
|
39
33
|
export interface ListCommunities {
|
40
34
|
type_?: ListingType;
|
41
35
|
sort?: SortType;
|
@@ -1,3 +1,4 @@
|
|
1
|
+
import { Option } from "@swan-io/boxed";
|
1
2
|
import { ListingType, SearchType, SortType } from "../others";
|
2
3
|
import { CommentView, CommunityBlockView, CommunityFollowerView, CommunityModeratorView, CommunityView, LocalUserSettingsView, ModAddCommunityView, ModAddView, ModBanFromCommunityView, ModBanView, ModLockPostView, ModRemoveCommentView, ModRemoveCommunityView, ModRemovePostView, ModStickyPostView, ModTransferCommunityView, PersonBlockView, PersonViewSafe, PostView, RegistrationApplicationView, SiteView } from "../views";
|
3
4
|
/**
|
@@ -49,7 +50,7 @@ export interface GetModlogResponse {
|
|
49
50
|
}
|
50
51
|
export interface CreateSite {
|
51
52
|
name: string;
|
52
|
-
sidebar
|
53
|
+
sidebar: Option<string>;
|
53
54
|
description?: string;
|
54
55
|
icon?: string;
|
55
56
|
banner?: string;
|
@@ -67,7 +68,7 @@ export interface CreateSite {
|
|
67
68
|
}
|
68
69
|
export interface EditSite {
|
69
70
|
name?: string;
|
70
|
-
sidebar
|
71
|
+
sidebar: Option<string>;
|
71
72
|
description?: string;
|
72
73
|
icon?: string;
|
73
74
|
banner?: string;
|
@@ -1,3 +1,4 @@
|
|
1
|
+
import { Option } from "@swan-io/boxed";
|
1
2
|
export interface LocalUserSettings {
|
2
3
|
id: number;
|
3
4
|
person_id: number;
|
@@ -39,7 +40,7 @@ export interface PersonSafe {
|
|
39
40
|
export interface Site {
|
40
41
|
id: number;
|
41
42
|
name: string;
|
42
|
-
sidebar
|
43
|
+
sidebar: Option<string>;
|
43
44
|
published: string;
|
44
45
|
updated?: string;
|
45
46
|
enable_downvotes: boolean;
|
package/package.json
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
{
|
2
2
|
"name": "lemmy-js-client",
|
3
3
|
"description": "A javascript / typescript client for Lemmy",
|
4
|
-
"version": "0.17.0-rc.
|
4
|
+
"version": "0.17.0-rc.13",
|
5
5
|
"author": "Dessalines <tyhou13@gmx.com>",
|
6
6
|
"license": "AGPL-3.0",
|
7
7
|
"main": "./dist/index.js",
|
@@ -16,6 +16,7 @@
|
|
16
16
|
},
|
17
17
|
"repository": "https://github.com/LemmyNet/lemmy-js-client",
|
18
18
|
"devDependencies": {
|
19
|
+
"@swan-io/boxed": "^0.9.0",
|
19
20
|
"@types/node": "^17.0.33",
|
20
21
|
"@types/node-fetch": "^3.0.3",
|
21
22
|
"@typescript-eslint/eslint-plugin": "^5.23.0",
|