From 973b255c829e78a0667f472db0ebd864c1ad7aa3 Mon Sep 17 00:00:00 2001 From: Dessalines Date: Tue, 29 Aug 2023 15:53:23 -0400 Subject: [PATCH 1/2] Updating moderator_view. --- putTypesInIndex.js | 4 ++-- src/types/AddAdmin.ts | 4 ++-- src/types/CommentResponse.ts | 1 - src/types/CreateComment.ts | 1 - src/types/DeleteAccount.ts | 1 + src/types/EditComment.ts | 1 - src/types/GetComments.ts | 2 ++ src/types/GetPosts.ts | 2 ++ src/types/GetPrivateMessages.ts | 2 ++ src/types/ListingType.ts | 2 +- src/types/LocalUser.ts | 1 + src/types/Person.ts | 1 - 12 files changed, 13 insertions(+), 9 deletions(-) diff --git a/putTypesInIndex.js b/putTypesInIndex.js index 976b21c..7936d29 100644 --- a/putTypesInIndex.js +++ b/putTypesInIndex.js @@ -23,8 +23,8 @@ async function putTypesInIndex() { exports.push( `export {${spacer}${localExports.join( - ",\n" - )}${spacer}} from "./types/${filename.replace(/\..+/, "")}";` + ",\n", + )}${spacer}} from "./types/${filename.replace(/\..+/, "")}";`, ); } diff --git a/src/types/AddAdmin.ts b/src/types/AddAdmin.ts index 23de2dd..e9c8a59 100644 --- a/src/types/AddAdmin.ts +++ b/src/types/AddAdmin.ts @@ -1,8 +1,8 @@ // This file was generated by [ts-rs](https://github.com/Aleph-Alpha/ts-rs). Do not edit this file manually. -import type { PersonId } from "./PersonId"; +import type { LocalUserId } from "./LocalUserId"; export interface AddAdmin { - person_id: PersonId; + local_user_id: LocalUserId; added: boolean; auth: string; } diff --git a/src/types/CommentResponse.ts b/src/types/CommentResponse.ts index 4d42e70..3e0d12e 100644 --- a/src/types/CommentResponse.ts +++ b/src/types/CommentResponse.ts @@ -5,5 +5,4 @@ import type { LocalUserId } from "./LocalUserId"; export interface CommentResponse { comment_view: CommentView; recipient_ids: Array; - form_id?: string; } diff --git a/src/types/CreateComment.ts b/src/types/CreateComment.ts index 6b9bd78..d62b342 100644 --- a/src/types/CreateComment.ts +++ b/src/types/CreateComment.ts @@ -8,6 +8,5 @@ export interface CreateComment { post_id: PostId; parent_id?: CommentId; language_id?: LanguageId; - form_id?: string; auth: string; } diff --git a/src/types/DeleteAccount.ts b/src/types/DeleteAccount.ts index ae61ed8..3c847e4 100644 --- a/src/types/DeleteAccount.ts +++ b/src/types/DeleteAccount.ts @@ -2,5 +2,6 @@ export interface DeleteAccount { password: string; + delete_content: boolean; auth: string; } diff --git a/src/types/EditComment.ts b/src/types/EditComment.ts index 1c2012b..27880df 100644 --- a/src/types/EditComment.ts +++ b/src/types/EditComment.ts @@ -6,6 +6,5 @@ export interface EditComment { comment_id: CommentId; content?: string; language_id?: LanguageId; - form_id?: string; auth: string; } diff --git a/src/types/GetComments.ts b/src/types/GetComments.ts index dabef71..8e9c863 100644 --- a/src/types/GetComments.ts +++ b/src/types/GetComments.ts @@ -16,5 +16,7 @@ export interface GetComments { post_id?: PostId; parent_id?: CommentId; saved_only?: boolean; + liked_only?: boolean; + disliked_only?: boolean; auth?: string; } diff --git a/src/types/GetPosts.ts b/src/types/GetPosts.ts index 5198bfa..e7c1b68 100644 --- a/src/types/GetPosts.ts +++ b/src/types/GetPosts.ts @@ -11,5 +11,7 @@ export interface GetPosts { community_id?: CommunityId; community_name?: string; saved_only?: boolean; + liked_only?: boolean; + disliked_only?: boolean; auth?: string; } diff --git a/src/types/GetPrivateMessages.ts b/src/types/GetPrivateMessages.ts index 009ea40..9bb22fe 100644 --- a/src/types/GetPrivateMessages.ts +++ b/src/types/GetPrivateMessages.ts @@ -1,8 +1,10 @@ // This file was generated by [ts-rs](https://github.com/Aleph-Alpha/ts-rs). Do not edit this file manually. +import type { PersonId } from "./PersonId"; export interface GetPrivateMessages { unread_only?: boolean; page?: number; limit?: number; + creator_id?: PersonId; auth: string; } diff --git a/src/types/ListingType.ts b/src/types/ListingType.ts index f392b20..0c9f03e 100644 --- a/src/types/ListingType.ts +++ b/src/types/ListingType.ts @@ -1,3 +1,3 @@ // This file was generated by [ts-rs](https://github.com/Aleph-Alpha/ts-rs). Do not edit this file manually. -export type ListingType = "All" | "Local" | "Subscribed" | "Moderator View"; +export type ListingType = "All" | "Local" | "Subscribed" | "ModeratorView"; diff --git a/src/types/LocalUser.ts b/src/types/LocalUser.ts index 8f14749..76af8b0 100644 --- a/src/types/LocalUser.ts +++ b/src/types/LocalUser.ts @@ -27,4 +27,5 @@ export interface LocalUser { blur_nsfw: boolean; auto_expand: boolean; infinite_scroll_enabled: boolean; + admin: boolean; } diff --git a/src/types/Person.ts b/src/types/Person.ts index b7a7bd2..137cfe4 100644 --- a/src/types/Person.ts +++ b/src/types/Person.ts @@ -17,7 +17,6 @@ export interface Person { deleted: boolean; inbox_url: string; matrix_user_id?: string; - admin: boolean; bot_account: boolean; ban_expires?: string; instance_id: InstanceId; From f2df2fb3658f0bc58ac0bcb743f098c833bf8f9e Mon Sep 17 00:00:00 2001 From: Dessalines Date: Tue, 29 Aug 2023 15:54:08 -0400 Subject: [PATCH 2/2] v0.19.0-rc.3 --- package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/package.json b/package.json index ba1d45e..9d2cec8 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "lemmy-js-client", - "version": "0.19.0-rc.1", + "version": "0.19.0-rc.3", "description": "A javascript / typescript client for Lemmy", "repository": "https://github.com/LemmyNet/lemmy-js-client", "license": "AGPL-3.0",