Compare commits

...

3 commits

Author SHA1 Message Date
Dessalines
916440e413 v0.18.1-rc.3 2023-07-03 18:39:35 -04:00
Dessalines
8fa91b55bb
Add open links in new tab. (#160) 2023-07-03 18:38:57 -04:00
Sander Saarend
d497a1efea
Handle 413 response on image uploads (#154)
Co-authored-by: Dessalines <dessalines@users.noreply.github.com>
2023-07-03 17:59:54 -04:00
6 changed files with 10 additions and 1 deletions

View file

@ -1,6 +1,6 @@
{
"name": "lemmy-js-client",
"version": "0.18.1-rc.2",
"version": "0.18.1-rc.3",
"description": "A javascript / typescript client for Lemmy",
"repository": "https://github.com/LemmyNet/lemmy-js-client",
"license": "AGPL-3.0",

View file

@ -1284,6 +1284,10 @@ export class LemmyHttp {
},
});
if (response.status === 413) {
return { msg: "too_large" };
}
const responseJson = await response.json();
if (responseJson.msg === "ok") {

View file

@ -16,6 +16,8 @@ export interface Community {
local: boolean;
icon?: string;
banner?: string;
followers_url: string;
inbox_url: string;
hidden: boolean;
posting_restricted_to_mods: boolean;
instance_id: InstanceId;

View file

@ -23,4 +23,5 @@ export interface LocalUser {
email_verified: boolean;
accepted_application: boolean;
totp_2fa_url?: string;
open_links_in_new_tab: boolean;
}

View file

@ -15,6 +15,7 @@ export interface Person {
local: boolean;
banner?: string;
deleted: boolean;
inbox_url: string;
matrix_user_id?: string;
admin: boolean;
bot_account: boolean;

View file

@ -25,4 +25,5 @@ export interface SaveUserSettings {
discussion_languages?: Array<LanguageId>;
generate_totp_2fa?: boolean;
auth: string;
open_links_in_new_tab?: boolean;
}