lemmy-js-client 0.19.4-alpha.6 → 0.19.4-alpha.7
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/http.d.ts +15 -0
- package/dist/http.js +16 -0
- package/dist/index.d.ts +4 -0
- package/dist/types/GetModlog.d.ts +4 -0
- package/dist/types/GetPosts.d.ts +1 -0
- package/dist/types/HidePost.d.ts +5 -0
- package/dist/types/HidePost.js +2 -0
- package/dist/types/LemmyErrorType.d.ts +2 -0
- package/dist/types/ListCommentReports.d.ts +2 -0
- package/dist/types/ListMedia.d.ts +4 -0
- package/dist/types/ListMedia.js +3 -0
- package/dist/types/ListMediaResponse.d.ts +4 -0
- package/dist/types/ListMediaResponse.js +2 -0
- package/dist/types/ListPostReports.d.ts +2 -0
- package/dist/types/LocalImage.d.ts +7 -0
- package/dist/types/LocalImage.js +2 -0
- package/dist/types/MarkPostAsRead.d.ts +1 -2
- package/dist/types/ModlogListParams.d.ts +4 -0
- package/dist/types/PostView.d.ts +1 -0
- package/package.json +1 -1
package/dist/http.d.ts
CHANGED
@@ -132,6 +132,9 @@ import { ListPostLikes } from "./types/ListPostLikes";
|
|
132
132
|
import { ListPostLikesResponse } from "./types/ListPostLikesResponse";
|
133
133
|
import { ListCommentLikes } from "./types/ListCommentLikes";
|
134
134
|
import { ListCommentLikesResponse } from "./types/ListCommentLikesResponse";
|
135
|
+
import { HidePost } from "./types/HidePost";
|
136
|
+
import { ListMedia } from "./types/ListMedia";
|
137
|
+
import { ListMediaResponse } from "./types/ListMediaResponse";
|
135
138
|
/**
|
136
139
|
* Helps build lemmy HTTP requests.
|
137
140
|
*/
|
@@ -205,6 +208,12 @@ export declare class LemmyHttp {
|
|
205
208
|
* `HTTP.GET /user/validate_auth`
|
206
209
|
*/
|
207
210
|
validateAuth(): Promise<SuccessResponse>;
|
211
|
+
/**
|
212
|
+
* List all the media for your user
|
213
|
+
*
|
214
|
+
* `HTTP.GET /user/list_media`
|
215
|
+
*/
|
216
|
+
listMedia(form: ListMedia): Promise<ListMediaResponse>;
|
208
217
|
/**
|
209
218
|
* Enable / Disable TOTP / two-factor authentication.
|
210
219
|
*
|
@@ -341,6 +350,12 @@ export declare class LemmyHttp {
|
|
341
350
|
* `HTTP.POST /post/mark_as_read`
|
342
351
|
*/
|
343
352
|
markPostAsRead(form: MarkPostAsRead): Promise<SuccessResponse>;
|
353
|
+
/**
|
354
|
+
* Hide a post from list views.
|
355
|
+
*
|
356
|
+
* `HTTP.POST /post/hide`
|
357
|
+
*/
|
358
|
+
hidePost(form: HidePost): Promise<SuccessResponse>;
|
344
359
|
/**
|
345
360
|
* A moderator can lock a post ( IE disable new comments ).
|
346
361
|
*
|
package/dist/http.js
CHANGED
@@ -133,6 +133,14 @@ class LemmyHttp {
|
|
133
133
|
validateAuth() {
|
134
134
|
return __classPrivateFieldGet(this, _LemmyHttp_instances, "m", _LemmyHttp_wrapper).call(this, HttpType.Get, "/user/validate_auth", {});
|
135
135
|
}
|
136
|
+
/**
|
137
|
+
* List all the media for your user
|
138
|
+
*
|
139
|
+
* `HTTP.GET /user/list_media`
|
140
|
+
*/
|
141
|
+
listMedia(form) {
|
142
|
+
return __classPrivateFieldGet(this, _LemmyHttp_instances, "m", _LemmyHttp_wrapper).call(this, HttpType.Get, "/user/list_media", form);
|
143
|
+
}
|
136
144
|
/**
|
137
145
|
* Enable / Disable TOTP / two-factor authentication.
|
138
146
|
*
|
@@ -313,6 +321,14 @@ class LemmyHttp {
|
|
313
321
|
markPostAsRead(form) {
|
314
322
|
return __classPrivateFieldGet(this, _LemmyHttp_instances, "m", _LemmyHttp_wrapper).call(this, HttpType.Post, "/post/mark_as_read", form);
|
315
323
|
}
|
324
|
+
/**
|
325
|
+
* Hide a post from list views.
|
326
|
+
*
|
327
|
+
* `HTTP.POST /post/hide`
|
328
|
+
*/
|
329
|
+
hidePost(form) {
|
330
|
+
return __classPrivateFieldGet(this, _LemmyHttp_instances, "m", _LemmyHttp_wrapper).call(this, HttpType.Post, "/post/hide", form);
|
331
|
+
}
|
316
332
|
/**
|
317
333
|
* A moderator can lock a post ( IE disable new comments ).
|
318
334
|
*
|
package/dist/index.d.ts
CHANGED
@@ -110,6 +110,7 @@ export { GetSiteResponse } from "./types/GetSiteResponse";
|
|
110
110
|
export { GetUnreadCountResponse } from "./types/GetUnreadCountResponse";
|
111
111
|
export { GetUnreadRegistrationApplicationCountResponse } from "./types/GetUnreadRegistrationApplicationCountResponse";
|
112
112
|
export { HideCommunity } from "./types/HideCommunity";
|
113
|
+
export { HidePost } from "./types/HidePost";
|
113
114
|
export { Instance } from "./types/Instance";
|
114
115
|
export { InstanceBlockView } from "./types/InstanceBlockView";
|
115
116
|
export { InstanceId } from "./types/InstanceId";
|
@@ -124,6 +125,8 @@ export { ListCommentReports } from "./types/ListCommentReports";
|
|
124
125
|
export { ListCommentReportsResponse } from "./types/ListCommentReportsResponse";
|
125
126
|
export { ListCommunities } from "./types/ListCommunities";
|
126
127
|
export { ListCommunitiesResponse } from "./types/ListCommunitiesResponse";
|
128
|
+
export { ListMedia } from "./types/ListMedia";
|
129
|
+
export { ListMediaResponse } from "./types/ListMediaResponse";
|
127
130
|
export { ListPostLikes } from "./types/ListPostLikes";
|
128
131
|
export { ListPostLikesResponse } from "./types/ListPostLikesResponse";
|
129
132
|
export { ListPostReports } from "./types/ListPostReports";
|
@@ -133,6 +136,7 @@ export { ListPrivateMessageReportsResponse } from "./types/ListPrivateMessageRep
|
|
133
136
|
export { ListRegistrationApplications } from "./types/ListRegistrationApplications";
|
134
137
|
export { ListRegistrationApplicationsResponse } from "./types/ListRegistrationApplicationsResponse";
|
135
138
|
export { ListingType } from "./types/ListingType";
|
139
|
+
export { LocalImage } from "./types/LocalImage";
|
136
140
|
export { LocalSite } from "./types/LocalSite";
|
137
141
|
export { LocalSiteId } from "./types/LocalSiteId";
|
138
142
|
export { LocalSiteRateLimit } from "./types/LocalSiteRateLimit";
|
@@ -1,6 +1,8 @@
|
|
1
|
+
import type { CommentId } from "./CommentId";
|
1
2
|
import type { CommunityId } from "./CommunityId";
|
2
3
|
import type { ModlogActionType } from "./ModlogActionType";
|
3
4
|
import type { PersonId } from "./PersonId";
|
5
|
+
import type { PostId } from "./PostId";
|
4
6
|
export interface GetModlog {
|
5
7
|
mod_person_id?: PersonId;
|
6
8
|
community_id?: CommunityId;
|
@@ -8,4 +10,6 @@ export interface GetModlog {
|
|
8
10
|
limit?: number;
|
9
11
|
type_?: ModlogActionType;
|
10
12
|
other_person_id?: PersonId;
|
13
|
+
post_id?: PostId;
|
14
|
+
comment_id?: CommentId;
|
11
15
|
}
|
package/dist/types/GetPosts.d.ts
CHANGED
@@ -1,9 +1,13 @@
|
|
1
|
+
import type { CommentId } from "./CommentId";
|
1
2
|
import type { CommunityId } from "./CommunityId";
|
2
3
|
import type { PersonId } from "./PersonId";
|
4
|
+
import type { PostId } from "./PostId";
|
3
5
|
export interface ModlogListParams {
|
4
6
|
community_id?: CommunityId;
|
5
7
|
mod_person_id?: PersonId;
|
6
8
|
other_person_id?: PersonId;
|
9
|
+
post_id?: PostId;
|
10
|
+
comment_id?: CommentId;
|
7
11
|
page?: number;
|
8
12
|
limit?: number;
|
9
13
|
hide_modlog_names: boolean;
|
package/dist/types/PostView.d.ts
CHANGED
package/package.json
CHANGED