@vlprojects-chat/chat 0.0.28 → 0.0.32
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/components/MessageList/MessageList.d.ts +0 -2
- package/dist/components/MessageList/components/MessageRow/MessageRow.d.ts +8 -0
- package/dist/components/MessageList/components/MessageRow/index.d.ts +1 -0
- package/dist/components/MessageList/components/SystemMessage/SystemMessage.d.ts +2 -2
- package/dist/components/MessageList/components/SystemMessage/components/ChangedChannel/ChangedChannel.d.ts +7 -0
- package/dist/components/MessageList/components/SystemMessage/components/ChangedChannel/index.d.ts +1 -0
- package/dist/components/MessageList/components/SystemMessage/components/UserChanged/UserChanged.d.ts +7 -0
- package/dist/components/MessageList/components/SystemMessage/components/UserChanged/index.d.ts +1 -0
- package/dist/components/MessageList/components/SystemMessage/components/UserChangedChannel/UserChangedChannel.d.ts +7 -0
- package/dist/components/MessageList/components/SystemMessage/components/UserChangedChannel/index.d.ts +1 -0
- package/dist/components/MessageList/components/SystemMessage/components/UserJoined/UserJoined.d.ts +7 -0
- package/dist/components/MessageList/components/SystemMessage/components/UserJoined/index.d.ts +1 -0
- package/dist/components/MessageList/components/UserMessage/UserMessage.d.ts +6 -10
- package/dist/components/MessageList/components/UserMessage/styles.d.ts +4 -2
- package/dist/components/MessageList/styles.d.ts +1 -1
- package/dist/containers/ChannelPage/ChannelPage.d.ts +3 -3
- package/dist/containers/PollPortal/styles.d.ts +1 -1
- package/dist/index.es.js +44 -22
- package/dist/index.js +44 -22
- package/dist/keystone/auth.d.ts +1 -0
- package/dist/keystone/chat/message.d.ts +36 -0
- package/dist/keystone/service.d.ts +1 -0
- package/dist/locales/index.d.ts +8 -0
- package/dist/theme/consts.d.ts +3 -0
- package/dist/types/serverResponses.d.ts +1 -0
- package/dist/types/socketEvents.d.ts +1 -1
- package/package.json +4 -3
package/dist/keystone/auth.d.ts
CHANGED
|
@@ -1,26 +1,62 @@
|
|
|
1
1
|
import { Ref } from 'mobx-keystone';
|
|
2
2
|
import { MessageTypeEnum } from '../../types/enums';
|
|
3
3
|
import User from './user';
|
|
4
|
+
import { Root } from '../index';
|
|
5
|
+
export declare enum SystemMessageEnum {
|
|
6
|
+
UserJoinedEvent = "user-joined",
|
|
7
|
+
UserChangedEvent = "user-changed",
|
|
8
|
+
UserChangedChannelEvent = "user-changed-channel",
|
|
9
|
+
ChangedChannelEvent = "changed-channel"
|
|
10
|
+
}
|
|
11
|
+
export interface SystemData {
|
|
12
|
+
event: SystemMessageEnum;
|
|
13
|
+
whoJoined?: Ref<User>;
|
|
14
|
+
whoRenamedChannel?: Ref<User>;
|
|
15
|
+
oldDisplayName?: string;
|
|
16
|
+
newDisplayName?: string;
|
|
17
|
+
newName?: string;
|
|
18
|
+
}
|
|
19
|
+
export interface UserJoinedPayload {
|
|
20
|
+
userId: string;
|
|
21
|
+
}
|
|
22
|
+
export interface UserChangedPayload {
|
|
23
|
+
oldDisplayName: string;
|
|
24
|
+
newDisplayName: string;
|
|
25
|
+
}
|
|
26
|
+
export interface UserChangedChannelPayload {
|
|
27
|
+
userId: string;
|
|
28
|
+
newName: string;
|
|
29
|
+
}
|
|
30
|
+
export interface ChangedChannelEventPayload {
|
|
31
|
+
newName: string;
|
|
32
|
+
}
|
|
4
33
|
declare const Message_base: import("mobx-keystone")._Model<unknown, {
|
|
5
34
|
id: import("mobx-keystone").MaybeOptionalModelProp<string>;
|
|
6
35
|
text: import("mobx-keystone").MaybeOptionalModelProp<string>;
|
|
7
36
|
type: import("mobx-keystone").MaybeOptionalModelProp<MessageTypeEnum>;
|
|
8
37
|
user: import("mobx-keystone").MaybeOptionalModelProp<Ref<User> | null>;
|
|
9
38
|
createdAt: import("mobx-keystone").MaybeOptionalModelProp<string>;
|
|
39
|
+
meta: import("mobx-keystone").MaybeOptionalModelProp<Record<string, unknown>>;
|
|
40
|
+
systemData: import("mobx-keystone").MaybeOptionalModelProp<SystemData | null>;
|
|
10
41
|
}, import("mobx-keystone").SnapshotInOfObject<import("mobx-keystone").ModelPropsToCreationData<{
|
|
11
42
|
id: import("mobx-keystone").MaybeOptionalModelProp<string>;
|
|
12
43
|
text: import("mobx-keystone").MaybeOptionalModelProp<string>;
|
|
13
44
|
type: import("mobx-keystone").MaybeOptionalModelProp<MessageTypeEnum>;
|
|
14
45
|
user: import("mobx-keystone").MaybeOptionalModelProp<Ref<User> | null>;
|
|
15
46
|
createdAt: import("mobx-keystone").MaybeOptionalModelProp<string>;
|
|
47
|
+
meta: import("mobx-keystone").MaybeOptionalModelProp<Record<string, unknown>>;
|
|
48
|
+
systemData: import("mobx-keystone").MaybeOptionalModelProp<SystemData | null>;
|
|
16
49
|
}>>, import("mobx-keystone").SnapshotOutOfObject<import("mobx-keystone").ModelPropsToData<{
|
|
17
50
|
id: import("mobx-keystone").MaybeOptionalModelProp<string>;
|
|
18
51
|
text: import("mobx-keystone").MaybeOptionalModelProp<string>;
|
|
19
52
|
type: import("mobx-keystone").MaybeOptionalModelProp<MessageTypeEnum>;
|
|
20
53
|
user: import("mobx-keystone").MaybeOptionalModelProp<Ref<User> | null>;
|
|
21
54
|
createdAt: import("mobx-keystone").MaybeOptionalModelProp<string>;
|
|
55
|
+
meta: import("mobx-keystone").MaybeOptionalModelProp<Record<string, unknown>>;
|
|
56
|
+
systemData: import("mobx-keystone").MaybeOptionalModelProp<SystemData | null>;
|
|
22
57
|
}>>>;
|
|
23
58
|
export default class Message extends Message_base {
|
|
24
59
|
get getUser(): User | undefined;
|
|
60
|
+
loadSystemData(root: Root, event: SystemMessageEnum, data: unknown): void;
|
|
25
61
|
}
|
|
26
62
|
export {};
|
|
@@ -3,6 +3,7 @@ export declare const getInitialData: (root: Root) => Promise<void>;
|
|
|
3
3
|
export declare const login: (root: Root, username: string, password?: string | undefined) => Promise<void>;
|
|
4
4
|
export declare const signup: (root: Root, username: string, password?: string | undefined) => Promise<void>;
|
|
5
5
|
export declare const saveProfile: (root: Root, displayName: string, avatar?: string | undefined) => Promise<void>;
|
|
6
|
+
export declare const loadChannelPolls: (root: Root, channelId: string) => Promise<void>;
|
|
6
7
|
export declare const joinChannel: (root: Root, id: string) => Promise<void>;
|
|
7
8
|
export declare const joinChannelByExternalId: (root: Root, externalId: string) => Promise<void>;
|
|
8
9
|
export declare const redirectToInitial: (root: Root) => Promise<void> | void;
|
package/dist/locales/index.d.ts
CHANGED
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
declare const _default: {
|
|
2
2
|
en: {
|
|
3
|
+
globalError: string;
|
|
3
4
|
messageInputPlaceholder: string;
|
|
4
5
|
channelName: string;
|
|
5
6
|
newChannel: string;
|
|
@@ -59,8 +60,12 @@ declare const _default: {
|
|
|
59
60
|
pinMessage: string;
|
|
60
61
|
deleteMessage: string;
|
|
61
62
|
deleteAllMessage: string;
|
|
63
|
+
systemMessageChangedName: string;
|
|
64
|
+
systemMessageUserChangedChannelName: string;
|
|
65
|
+
systemMessageChangedChannelName: string;
|
|
62
66
|
};
|
|
63
67
|
ru: {
|
|
68
|
+
globalError: string;
|
|
64
69
|
messageInputPlaceholder: string;
|
|
65
70
|
channelName: string;
|
|
66
71
|
newChannel: string;
|
|
@@ -120,6 +125,9 @@ declare const _default: {
|
|
|
120
125
|
pinMessage: string;
|
|
121
126
|
deleteMessage: string;
|
|
122
127
|
deleteAllMessage: string;
|
|
128
|
+
systemMessageChangedName: string;
|
|
129
|
+
systemMessageUserChangedChannelName: string;
|
|
130
|
+
systemMessageChangedChannelName: string;
|
|
123
131
|
};
|
|
124
132
|
};
|
|
125
133
|
export default _default;
|
package/dist/theme/consts.d.ts
CHANGED
|
@@ -10,6 +10,6 @@ declare enum SocketEventsEnum {
|
|
|
10
10
|
UserUpdateProfile = "user-update-profile",
|
|
11
11
|
MessagePinned = "message-pinned",
|
|
12
12
|
DeleteMessages = "delete-messages",
|
|
13
|
-
CleanChannelMessages = "
|
|
13
|
+
CleanChannelMessages = "clean-channel-messages"
|
|
14
14
|
}
|
|
15
15
|
export default SocketEventsEnum;
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@vlprojects-chat/chat",
|
|
3
3
|
"author": "vlprojects",
|
|
4
|
-
"version": "0.0.
|
|
4
|
+
"version": "0.0.32",
|
|
5
5
|
"description": "chat",
|
|
6
6
|
"license": "ISC",
|
|
7
7
|
"main": "dist/index.js",
|
|
@@ -52,10 +52,12 @@
|
|
|
52
52
|
"mobx-utils": "^6.0.4",
|
|
53
53
|
"notistack": "^2.0.2",
|
|
54
54
|
"qs": "^6.10.1",
|
|
55
|
+
"react-error-boundary": "^3.1.4",
|
|
55
56
|
"react-final-form": "^6.5.7",
|
|
56
57
|
"react-final-form-arrays": "^3.1.3",
|
|
58
|
+
"react-intersection-observer": "^8.33.0",
|
|
57
59
|
"react-intl": "^5.21.0",
|
|
58
|
-
"react-
|
|
60
|
+
"react-virtuoso": "^2.2.8",
|
|
59
61
|
"route-parser": "^0.0.5"
|
|
60
62
|
},
|
|
61
63
|
"devDependencies": {
|
|
@@ -77,7 +79,6 @@
|
|
|
77
79
|
"@types/react-dom": "^17.0.10",
|
|
78
80
|
"@types/react-linkify": "^1.0.1",
|
|
79
81
|
"@types/react-router-dom": "^5.3.1",
|
|
80
|
-
"@types/react-virtualized": "^9.21.14",
|
|
81
82
|
"@types/route-parser": "^0.1.3",
|
|
82
83
|
"@types/socket.io": "^3.0.2",
|
|
83
84
|
"@typescript-eslint/eslint-plugin": "^4.33.0",
|