lemmy-js-client 0.17.0-rc.11 → 0.17.0-rc.14
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.
@@ -1,3 +1,4 @@
|
|
1
|
+
import { Option } from "option-t/esm/PlainOption";
|
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;
|
@@ -143,14 +143,6 @@ export declare enum SearchType {
|
|
143
143
|
Users = "Users",
|
144
144
|
Url = "Url"
|
145
145
|
}
|
146
|
-
/**
|
147
|
-
* Different Subscribed states
|
148
|
-
*/
|
149
|
-
export declare enum SubscribedType {
|
150
|
-
Subscribed = "Subscribed",
|
151
|
-
NotSubscribed = "NotSubscribed",
|
152
|
-
Pending = "Pending"
|
153
|
-
}
|
154
146
|
/**
|
155
147
|
* A websocket response. Includes the return type.
|
156
148
|
* Can be used like:
|
@@ -1,6 +1,6 @@
|
|
1
1
|
"use strict";
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
3
|
-
exports.
|
3
|
+
exports.SearchType = exports.ListingType = exports.SortType = exports.UserOperation = exports.VERSION = void 0;
|
4
4
|
exports.VERSION = "v3";
|
5
5
|
/**
|
6
6
|
* All of the websocket operations available.
|
@@ -150,12 +150,3 @@ var SearchType;
|
|
150
150
|
SearchType["Users"] = "Users";
|
151
151
|
SearchType["Url"] = "Url";
|
152
152
|
})(SearchType = exports.SearchType || (exports.SearchType = {}));
|
153
|
-
/**
|
154
|
-
* Different Subscribed states
|
155
|
-
*/
|
156
|
-
var SubscribedType;
|
157
|
-
(function (SubscribedType) {
|
158
|
-
SubscribedType["Subscribed"] = "Subscribed";
|
159
|
-
SubscribedType["NotSubscribed"] = "NotSubscribed";
|
160
|
-
SubscribedType["Pending"] = "Pending";
|
161
|
-
})(SubscribedType = exports.SubscribedType || (exports.SubscribedType = {}));
|
@@ -1,3 +1,4 @@
|
|
1
|
+
import { Option } from "option-t/esm/PlainOption";
|
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;
|
@@ -1,5 +1,4 @@
|
|
1
1
|
import { CommentAggregates, CommunityAggregates, PersonAggregates, PostAggregates, SiteAggregates } from "./aggregates";
|
2
|
-
import { SubscribedType } from "./others";
|
3
2
|
import { Comment, CommentReport, CommunitySafe, LocalUserSettings, ModAdd, ModAddCommunity, ModBan, ModBanFromCommunity, ModLockPost, ModRemoveComment, ModRemoveCommunity, ModRemovePost, ModStickyPost, ModTransferCommunity, PersonMention, PersonSafe, Post, PostReport, PrivateMessage, RegistrationApplication, Site } from "./source";
|
4
3
|
export interface PersonViewSafe {
|
5
4
|
person: PersonSafe;
|
@@ -14,7 +13,7 @@ export interface PersonMentionView {
|
|
14
13
|
recipient: PersonSafe;
|
15
14
|
counts: CommentAggregates;
|
16
15
|
creator_banned_from_community: boolean;
|
17
|
-
subscribed:
|
16
|
+
subscribed: boolean;
|
18
17
|
saved: boolean;
|
19
18
|
creator_blocked: boolean;
|
20
19
|
my_vote?: number;
|
@@ -39,7 +38,7 @@ export interface PostView {
|
|
39
38
|
community: CommunitySafe;
|
40
39
|
creator_banned_from_community: boolean;
|
41
40
|
counts: PostAggregates;
|
42
|
-
subscribed:
|
41
|
+
subscribed: boolean;
|
43
42
|
saved: boolean;
|
44
43
|
read: boolean;
|
45
44
|
creator_blocked: boolean;
|
@@ -64,7 +63,7 @@ export interface CommentView {
|
|
64
63
|
community: CommunitySafe;
|
65
64
|
counts: CommentAggregates;
|
66
65
|
creator_banned_from_community: boolean;
|
67
|
-
subscribed:
|
66
|
+
subscribed: boolean;
|
68
67
|
saved: boolean;
|
69
68
|
creator_blocked: boolean;
|
70
69
|
my_vote?: number;
|
@@ -143,7 +142,6 @@ export interface ModStickyPostView {
|
|
143
142
|
export interface CommunityFollowerView {
|
144
143
|
community: CommunitySafe;
|
145
144
|
follower: PersonSafe;
|
146
|
-
pending: boolean;
|
147
145
|
}
|
148
146
|
export interface CommunityBlockView {
|
149
147
|
person: PersonSafe;
|
@@ -163,7 +161,7 @@ export interface PersonBlockView {
|
|
163
161
|
}
|
164
162
|
export interface CommunityView {
|
165
163
|
community: CommunitySafe;
|
166
|
-
subscribed:
|
164
|
+
subscribed: boolean;
|
167
165
|
blocked: boolean;
|
168
166
|
counts: CommunityAggregates;
|
169
167
|
}
|
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.14",
|
5
5
|
"author": "Dessalines <tyhou13@gmx.com>",
|
6
6
|
"license": "AGPL-3.0",
|
7
7
|
"main": "./dist/index.js",
|
@@ -25,6 +25,7 @@
|
|
25
25
|
"husky": "^8.0.1",
|
26
26
|
"lint-staged": "^12.4.1",
|
27
27
|
"node-fetch": "^3.2.4",
|
28
|
+
"option-t": "^32.2.0",
|
28
29
|
"prettier": "^2.6.2",
|
29
30
|
"prettier-plugin-import-sort": "^0.0.7",
|
30
31
|
"prettier-plugin-organize-imports": "^2.3.4",
|