stream-chat-react 8.1.1 → 8.1.3
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/browser.full-bundle.js +86 -96
- package/dist/browser.full-bundle.js.map +1 -1
- package/dist/browser.full-bundle.min.js +4 -4
- package/dist/browser.full-bundle.min.js.map +1 -1
- package/dist/components/Channel/hooks/useCreateChannelStateContext.js +2 -2
- package/dist/components/ChannelPreview/ChannelPreview.d.ts.map +1 -1
- package/dist/components/ChannelPreview/ChannelPreview.js +20 -4
- package/dist/components/ChatDown/ChatDown.d.ts +5 -5
- package/dist/components/ChatDown/ChatDown.d.ts.map +1 -1
- package/dist/components/ChatDown/ChatDown.js +4 -4
- package/dist/components/ChatDown/icons.d.ts +2 -0
- package/dist/components/ChatDown/icons.d.ts.map +1 -0
- package/dist/components/ChatDown/icons.js +7 -0
- package/dist/components/Gallery/Gallery.d.ts.map +1 -1
- package/dist/components/Gallery/Gallery.js +11 -8
- package/dist/components/Message/utils.d.ts.map +1 -1
- package/dist/components/Message/utils.js +5 -10
- package/dist/components/MessageInput/MessageInput.d.ts +2 -1
- package/dist/components/MessageInput/MessageInput.d.ts.map +1 -1
- package/dist/components/MessageInput/hooks/useSubmitHandler.d.ts.map +1 -1
- package/dist/components/MessageInput/hooks/useSubmitHandler.js +17 -15
- package/dist/components/Thread/Thread.js +50 -10
- package/dist/index.cjs.js +79 -54
- package/dist/index.cjs.js.map +1 -1
- package/dist/stories/{connected-user.stories.d.ts → add-message.stories.d.ts} +1 -1
- package/dist/stories/add-message.stories.d.ts.map +1 -0
- package/dist/stories/{connected-user.stories.js → add-message.stories.js} +6 -7
- package/dist/stories/hello.stories.d.ts.map +1 -1
- package/dist/stories/hello.stories.js +11 -35
- package/dist/stories/jump-to-message.stories.d.ts +2 -2
- package/dist/stories/jump-to-message.stories.d.ts.map +1 -1
- package/dist/stories/jump-to-message.stories.js +18 -51
- package/dist/stories/mark-read.stories.d.ts.map +1 -1
- package/dist/stories/mark-read.stories.js +4 -27
- package/dist/stories/navigate-long-message-lists.stories.d.ts +4 -0
- package/dist/stories/navigate-long-message-lists.stories.d.ts.map +1 -0
- package/dist/stories/navigate-long-message-lists.stories.js +167 -0
- package/dist/stories/utils.d.ts +2 -3
- package/dist/stories/utils.d.ts.map +1 -1
- package/dist/stories/utils.js +14 -14
- package/dist/version.d.ts +1 -1
- package/dist/version.js +1 -1
- package/package.json +7 -5
- package/dist/assets/str-chat__alert.svg +0 -1
- package/dist/assets/str-chat__connection-error.svg +0 -13
- package/dist/assets/str-chat__file-file.svg +0 -20
- package/dist/assets/str-chat__icon-chevron-down.svg +0 -1
- package/dist/assets/str-chat__icon-search.svg +0 -1
- package/dist/assets/str-chat__icon-send.svg +0 -1
- package/dist/assets/str-chat__icon-sprite.png +0 -0
- package/dist/assets/str-chat__icon-sprite@1x.png +0 -0
- package/dist/assets/str-chat__icon-sprite@2x.png +0 -0
- package/dist/assets/str-chat__icon-sprite@3x.png +0 -0
- package/dist/assets/str-chat__loading-indicator.svg +0 -23
- package/dist/assets/str-chat__reactions-sprite@1x.png +0 -0
- package/dist/assets/str-chat__reactions-sprite@2x.png +0 -0
- package/dist/assets/str-chat__reactions-sprite@3x.png +0 -0
- package/dist/stories/connected-user.stories.d.ts.map +0 -1
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"add-message.stories.d.ts","sourceRoot":"","sources":["../../src/stories/add-message.stories.tsx"],"names":[],"mappings":"AACA,OAAO,+CAA+C,CAAC;AA8DvD,eAAO,MAAM,KAAK,mBAUjB,CAAC;AAEF,eAAO,MAAM,KAAK,mBAUjB,CAAC"}
|
|
@@ -1,9 +1,8 @@
|
|
|
1
1
|
/* eslint-disable @typescript-eslint/no-explicit-any */
|
|
2
2
|
import '@stream-io/stream-chat-css/dist/css/index.css';
|
|
3
3
|
import React from 'react';
|
|
4
|
-
import {
|
|
5
|
-
import {
|
|
6
|
-
import { apiKey, ConnectedUser } from './utils';
|
|
4
|
+
import { Channel, ChannelHeader, ChannelList, MessageList, Thread, useChannelStateContext, Window, } from '../index';
|
|
5
|
+
import { ConnectedUser } from './utils';
|
|
7
6
|
var channelId = import.meta.env.E2E_ADD_MESSAGE_CHANNEL;
|
|
8
7
|
if (!channelId || typeof channelId !== 'string') {
|
|
9
8
|
throw new Error('expected ADD_MESSAGE_CHANNEL');
|
|
@@ -20,16 +19,16 @@ var Controls = function () {
|
|
|
20
19
|
};
|
|
21
20
|
// Sort in reverse order to avoid auto-selecting unread channel
|
|
22
21
|
var sort = { last_updated: 1 };
|
|
23
|
-
var chatClient = StreamChat.getInstance(apiKey);
|
|
24
22
|
var WrappedConnectedUser = function (_a) {
|
|
25
23
|
var token = _a.token, userId = _a.userId;
|
|
26
|
-
return (React.createElement(ConnectedUser, {
|
|
27
|
-
React.createElement(ChannelList, { filters: { members: { $in: [userId] } }, sort: sort }),
|
|
24
|
+
return (React.createElement(ConnectedUser, { token: token, userId: userId },
|
|
25
|
+
React.createElement(ChannelList, { filters: { id: { $eq: 'add-message' }, members: { $in: [userId] } }, setActiveChannelOnMount: false, sort: sort }),
|
|
28
26
|
React.createElement(Channel, null,
|
|
29
27
|
React.createElement(Window, null,
|
|
30
28
|
React.createElement(ChannelHeader, null),
|
|
31
29
|
React.createElement(MessageList, null),
|
|
32
|
-
React.createElement(Controls, null))
|
|
30
|
+
React.createElement(Controls, null)),
|
|
31
|
+
React.createElement(Thread, null))));
|
|
33
32
|
};
|
|
34
33
|
export var User1 = function () {
|
|
35
34
|
var userId = import.meta.env.E2E_TEST_USER_1;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"hello.stories.d.ts","sourceRoot":"","sources":["../../src/stories/hello.stories.tsx"],"names":[],"mappings":"AACA,OAAO,+CAA+C,CAAC;
|
|
1
|
+
{"version":3,"file":"hello.stories.d.ts","sourceRoot":"","sources":["../../src/stories/hello.stories.tsx"],"names":[],"mappings":"AACA,OAAO,+CAA+C,CAAC;AA2BvD,eAAO,MAAM,UAAU,mBAYtB,CAAC"}
|
|
@@ -1,9 +1,8 @@
|
|
|
1
1
|
/* eslint-disable @typescript-eslint/no-explicit-any */
|
|
2
2
|
import '@stream-io/stream-chat-css/dist/css/index.css';
|
|
3
|
-
import React
|
|
4
|
-
import {
|
|
5
|
-
import {
|
|
6
|
-
import { apiKey } from './utils';
|
|
3
|
+
import React from 'react';
|
|
4
|
+
import { Channel, ChannelHeader, ChannelList, MessageInput, MessageList, Thread, Window, } from '../index';
|
|
5
|
+
import { ConnectedUser } from './utils';
|
|
7
6
|
var channelId = import.meta.env.E2E_ADD_MESSAGE_CHANNEL;
|
|
8
7
|
var userId = import.meta.env.E2E_TEST_USER_1;
|
|
9
8
|
var token = import.meta.env.E2E_TEST_USER_1_TOKEN;
|
|
@@ -14,34 +13,11 @@ if (!channelId || typeof channelId !== 'string') {
|
|
|
14
13
|
var sort = { last_updated: 1 };
|
|
15
14
|
var filters = { members: { $in: [userId] }, type: 'messaging' };
|
|
16
15
|
var options = { limit: 10, presence: true, state: true };
|
|
17
|
-
var
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
setConnected(online);
|
|
26
|
-
};
|
|
27
|
-
chatClient.on('connection.changed', handleConnectionChange);
|
|
28
|
-
return function () {
|
|
29
|
-
chatClient.off('connection.changed', handleConnectionChange);
|
|
30
|
-
sharedPromise = chatClient.disconnectUser();
|
|
31
|
-
};
|
|
32
|
-
}, []);
|
|
33
|
-
if (!connected) {
|
|
34
|
-
return React.createElement("p", null,
|
|
35
|
-
"Connecting ",
|
|
36
|
-
userId,
|
|
37
|
-
"...");
|
|
38
|
-
}
|
|
39
|
-
return (React.createElement(Chat, { client: chatClient },
|
|
40
|
-
React.createElement(ChannelList, { filters: filters, options: options, showChannelSearch: true, sort: sort }),
|
|
41
|
-
React.createElement(Channel, null,
|
|
42
|
-
React.createElement(Window, null,
|
|
43
|
-
React.createElement(ChannelHeader, null),
|
|
44
|
-
React.createElement(MessageList, null),
|
|
45
|
-
React.createElement(MessageInput, { focus: true })),
|
|
46
|
-
React.createElement(Thread, null))));
|
|
47
|
-
};
|
|
16
|
+
export var BasicSetup = function () { return (React.createElement(ConnectedUser, { token: token, userId: userId },
|
|
17
|
+
React.createElement(ChannelList, { filters: filters, options: options, showChannelSearch: true, sort: sort }),
|
|
18
|
+
React.createElement(Channel, null,
|
|
19
|
+
React.createElement(Window, null,
|
|
20
|
+
React.createElement(ChannelHeader, null),
|
|
21
|
+
React.createElement(MessageList, null),
|
|
22
|
+
React.createElement(MessageInput, { focus: true })),
|
|
23
|
+
React.createElement(Thread, null)))); };
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
import '@stream-io/stream-chat-css/dist/css/index.css';
|
|
2
|
-
export declare const JumpInRegularMessageList: () => JSX.Element
|
|
3
|
-
export declare const JumpInVirtualizedMessageList: () => JSX.Element
|
|
2
|
+
export declare const JumpInRegularMessageList: () => JSX.Element;
|
|
3
|
+
export declare const JumpInVirtualizedMessageList: () => JSX.Element;
|
|
4
4
|
//# sourceMappingURL=jump-to-message.stories.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"jump-to-message.stories.d.ts","sourceRoot":"","sources":["../../src/stories/jump-to-message.stories.tsx"],"names":[],"mappings":"AAWA,OAAO,+CAA+C,CAAC;
|
|
1
|
+
{"version":3,"file":"jump-to-message.stories.d.ts","sourceRoot":"","sources":["../../src/stories/jump-to-message.stories.tsx"],"names":[],"mappings":"AAWA,OAAO,+CAA+C,CAAC;AAkCvD,eAAO,MAAM,wBAAwB,mBAYpC,CAAC;AAEF,eAAO,MAAM,4BAA4B,mBAYxC,CAAC"}
|
|
@@ -35,20 +35,18 @@ var __generator = (this && this.__generator) || function (thisArg, body) {
|
|
|
35
35
|
}
|
|
36
36
|
};
|
|
37
37
|
/* eslint-disable @typescript-eslint/no-explicit-any */
|
|
38
|
-
import React
|
|
39
|
-
import {
|
|
40
|
-
import { Channel, Chat, MessageList, useChannelActionContext, VirtualizedMessageList, Window, } from '../index';
|
|
38
|
+
import React from 'react';
|
|
39
|
+
import { Channel, ChannelList, MessageList, useChannelActionContext, useChatContext, VirtualizedMessageList, Window, } from '../index';
|
|
41
40
|
import '@stream-io/stream-chat-css/dist/css/index.css';
|
|
41
|
+
import { ConnectedUser } from './utils';
|
|
42
42
|
void MessageList;
|
|
43
43
|
void VirtualizedMessageList;
|
|
44
|
-
var apiKey = import.meta.env.E2E_APP_KEY;
|
|
45
44
|
var userId = import.meta.env.E2E_TEST_USER_1;
|
|
46
45
|
var userToken = import.meta.env.E2E_TEST_USER_1_TOKEN;
|
|
47
46
|
var channelId = import.meta.env.E2E_JUMP_TO_MESSAGE_CHANNEL;
|
|
48
|
-
var chatClient = StreamChat.getInstance(apiKey);
|
|
49
|
-
chatClient.connectUser({ id: userId }, userToken);
|
|
50
47
|
var JumpToMessage = function () {
|
|
51
48
|
var jumpToMessage = useChannelActionContext().jumpToMessage;
|
|
49
|
+
var chatClient = useChatContext().client;
|
|
52
50
|
return (React.createElement("button", { "data-testid": 'jump-to-message', onClick: function () { return __awaiter(void 0, void 0, void 0, function () {
|
|
53
51
|
var results;
|
|
54
52
|
return __generator(this, function (_a) {
|
|
@@ -64,48 +62,17 @@ var JumpToMessage = function () {
|
|
|
64
62
|
});
|
|
65
63
|
}); } }, "Jump to message '29'"));
|
|
66
64
|
};
|
|
67
|
-
var
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
}
|
|
81
|
-
});
|
|
82
|
-
}); })();
|
|
83
|
-
}, []);
|
|
84
|
-
return channel;
|
|
85
|
-
};
|
|
86
|
-
export var JumpInRegularMessageList = function () {
|
|
87
|
-
var channel = useTheJumpChannel();
|
|
88
|
-
if (!channel) {
|
|
89
|
-
return null;
|
|
90
|
-
}
|
|
91
|
-
return (React.createElement("div", null,
|
|
92
|
-
React.createElement(StyleFix, null),
|
|
93
|
-
React.createElement(Chat, { client: chatClient },
|
|
94
|
-
React.createElement(Channel, { channel: channel },
|
|
95
|
-
React.createElement(JumpToMessage, null),
|
|
96
|
-
React.createElement(Window, null,
|
|
97
|
-
React.createElement(MessageList, null))))));
|
|
98
|
-
};
|
|
99
|
-
export var JumpInVirtualizedMessageList = function () {
|
|
100
|
-
var channel = useTheJumpChannel();
|
|
101
|
-
if (!channel) {
|
|
102
|
-
return null;
|
|
103
|
-
}
|
|
104
|
-
return (React.createElement("div", null,
|
|
105
|
-
React.createElement(StyleFix, null),
|
|
106
|
-
React.createElement(Chat, { client: chatClient },
|
|
107
|
-
React.createElement(Channel, { channel: channel },
|
|
108
|
-
React.createElement(JumpToMessage, null),
|
|
109
|
-
React.createElement(Window, null,
|
|
110
|
-
React.createElement(VirtualizedMessageList, null))))));
|
|
111
|
-
};
|
|
65
|
+
export var JumpInRegularMessageList = function () { return (React.createElement("div", null,
|
|
66
|
+
React.createElement(ConnectedUser, { token: userToken, userId: userId },
|
|
67
|
+
React.createElement(ChannelList, { filters: { id: { $eq: channelId } } }),
|
|
68
|
+
React.createElement(Channel, null,
|
|
69
|
+
React.createElement(JumpToMessage, null),
|
|
70
|
+
React.createElement(Window, null,
|
|
71
|
+
React.createElement(MessageList, null)))))); };
|
|
72
|
+
export var JumpInVirtualizedMessageList = function () { return (React.createElement("div", null,
|
|
73
|
+
React.createElement(ConnectedUser, { token: userToken, userId: userId },
|
|
74
|
+
React.createElement(ChannelList, { filters: { id: { $eq: channelId } } }),
|
|
75
|
+
React.createElement(Channel, null,
|
|
76
|
+
React.createElement(JumpToMessage, null),
|
|
77
|
+
React.createElement(Window, null,
|
|
78
|
+
React.createElement(VirtualizedMessageList, null)))))); };
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"mark-read.stories.d.ts","sourceRoot":"","sources":["../../src/stories/mark-read.stories.tsx"],"names":[],"mappings":"AACA,OAAO,+CAA+C,CAAC;
|
|
1
|
+
{"version":3,"file":"mark-read.stories.d.ts","sourceRoot":"","sources":["../../src/stories/mark-read.stories.tsx"],"names":[],"mappings":"AACA,OAAO,+CAA+C,CAAC;AA6DvD,eAAO,MAAM,KAAK,mBAUjB,CAAC;AAEF,eAAO,MAAM,KAAK,mBAUjB,CAAC"}
|
|
@@ -1,21 +1,9 @@
|
|
|
1
|
-
var __assign = (this && this.__assign) || function () {
|
|
2
|
-
__assign = Object.assign || function(t) {
|
|
3
|
-
for (var s, i = 1, n = arguments.length; i < n; i++) {
|
|
4
|
-
s = arguments[i];
|
|
5
|
-
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))
|
|
6
|
-
t[p] = s[p];
|
|
7
|
-
}
|
|
8
|
-
return t;
|
|
9
|
-
};
|
|
10
|
-
return __assign.apply(this, arguments);
|
|
11
|
-
};
|
|
12
1
|
/* eslint-disable @typescript-eslint/no-explicit-any */
|
|
13
2
|
import '@stream-io/stream-chat-css/dist/css/index.css';
|
|
14
3
|
import React from 'react';
|
|
15
|
-
import { StreamChat } from 'stream-chat';
|
|
16
4
|
import { v4 as uuid } from 'uuid';
|
|
17
|
-
import { Channel, ChannelHeader, ChannelList,
|
|
18
|
-
import {
|
|
5
|
+
import { Channel, ChannelHeader, ChannelList, MessageList, useChannelStateContext, Window, } from '../index';
|
|
6
|
+
import { ConnectedUser } from './utils';
|
|
19
7
|
var channelId = import.meta.env.E2E_ADD_MESSAGE_CHANNEL;
|
|
20
8
|
if (!channelId || typeof channelId !== 'string') {
|
|
21
9
|
throw new Error('expected ADD_MESSAGE_CHANNEL');
|
|
@@ -32,21 +20,10 @@ var Controls = function () {
|
|
|
32
20
|
};
|
|
33
21
|
// Sort in reverse order to avoid auto-selecting unread channel
|
|
34
22
|
var sort = { last_updated: 1 };
|
|
35
|
-
var chatClient = StreamChat.getInstance(apiKey);
|
|
36
|
-
var Custom = function (_a) {
|
|
37
|
-
var _b, _c;
|
|
38
|
-
var activeChannel = _a.activeChannel, channel = _a.channel, displayTitle = _a.displayTitle, setActiveChannel = _a.setActiveChannel, unread = _a.unread, watchers = _a.watchers;
|
|
39
|
-
var avatarName = displayTitle || ((_c = (_b = channel.state.messages[channel.state.messages.length - 1]) === null || _b === void 0 ? void 0 : _b.user) === null || _c === void 0 ? void 0 : _c.id);
|
|
40
|
-
return (React.createElement("div", { "data-testid": "channel-" + channel.id, onClick: function () { return setActiveChannel === null || setActiveChannel === void 0 ? void 0 : setActiveChannel(channel, watchers); }, style: { background: channel.cid === (activeChannel === null || activeChannel === void 0 ? void 0 : activeChannel.cid) ? '#fff' : 'initial' } },
|
|
41
|
-
React.createElement("span", null, avatarName),
|
|
42
|
-
" || ",
|
|
43
|
-
React.createElement("span", { "data-testid": 'unread-count' }, unread)));
|
|
44
|
-
};
|
|
45
|
-
var CustomPreview = function (props) { return (React.createElement(ChannelPreview, __assign({}, props, { Preview: Custom }))); };
|
|
46
23
|
var WrappedConnectedUser = function (_a) {
|
|
47
24
|
var token = _a.token, userId = _a.userId;
|
|
48
|
-
return (React.createElement(ConnectedUser, {
|
|
49
|
-
React.createElement(ChannelList, { filters: { members: { $in: [userId] }, name: { $autocomplete: 'mr-channel' } },
|
|
25
|
+
return (React.createElement(ConnectedUser, { token: token, userId: userId },
|
|
26
|
+
React.createElement(ChannelList, { filters: { members: { $in: [userId] }, name: { $autocomplete: 'mr-channel' } }, setActiveChannelOnMount: false, sort: sort }),
|
|
50
27
|
React.createElement(Channel, null,
|
|
51
28
|
React.createElement(Window, null,
|
|
52
29
|
React.createElement(ChannelHeader, null),
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"navigate-long-message-lists.stories.d.ts","sourceRoot":"","sources":["../../src/stories/navigate-long-message-lists.stories.tsx"],"names":[],"mappings":"AACA,OAAO,+CAA+C,CAAC;AAgKvD,eAAO,MAAM,KAAK,mBAQjB,CAAC;AAEF,eAAO,MAAM,KAAK,mBAQjB,CAAC"}
|
|
@@ -0,0 +1,167 @@
|
|
|
1
|
+
var __assign = (this && this.__assign) || function () {
|
|
2
|
+
__assign = Object.assign || function(t) {
|
|
3
|
+
for (var s, i = 1, n = arguments.length; i < n; i++) {
|
|
4
|
+
s = arguments[i];
|
|
5
|
+
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))
|
|
6
|
+
t[p] = s[p];
|
|
7
|
+
}
|
|
8
|
+
return t;
|
|
9
|
+
};
|
|
10
|
+
return __assign.apply(this, arguments);
|
|
11
|
+
};
|
|
12
|
+
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
13
|
+
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
14
|
+
return new (P || (P = Promise))(function (resolve, reject) {
|
|
15
|
+
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
|
16
|
+
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
|
|
17
|
+
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
|
|
18
|
+
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
19
|
+
});
|
|
20
|
+
};
|
|
21
|
+
var __generator = (this && this.__generator) || function (thisArg, body) {
|
|
22
|
+
var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;
|
|
23
|
+
return g = { next: verb(0), "throw": verb(1), "return": verb(2) }, typeof Symbol === "function" && (g[Symbol.iterator] = function() { return this; }), g;
|
|
24
|
+
function verb(n) { return function (v) { return step([n, v]); }; }
|
|
25
|
+
function step(op) {
|
|
26
|
+
if (f) throw new TypeError("Generator is already executing.");
|
|
27
|
+
while (_) try {
|
|
28
|
+
if (f = 1, y && (t = op[0] & 2 ? y["return"] : op[0] ? y["throw"] || ((t = y["return"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;
|
|
29
|
+
if (y = 0, t) op = [op[0] & 2, t.value];
|
|
30
|
+
switch (op[0]) {
|
|
31
|
+
case 0: case 1: t = op; break;
|
|
32
|
+
case 4: _.label++; return { value: op[1], done: false };
|
|
33
|
+
case 5: _.label++; y = op[1]; op = [0]; continue;
|
|
34
|
+
case 7: op = _.ops.pop(); _.trys.pop(); continue;
|
|
35
|
+
default:
|
|
36
|
+
if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }
|
|
37
|
+
if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }
|
|
38
|
+
if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }
|
|
39
|
+
if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }
|
|
40
|
+
if (t[2]) _.ops.pop();
|
|
41
|
+
_.trys.pop(); continue;
|
|
42
|
+
}
|
|
43
|
+
op = body.call(thisArg, _);
|
|
44
|
+
} catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }
|
|
45
|
+
if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };
|
|
46
|
+
}
|
|
47
|
+
};
|
|
48
|
+
/* eslint-disable @typescript-eslint/no-explicit-any */
|
|
49
|
+
import '@stream-io/stream-chat-css/dist/css/index.css';
|
|
50
|
+
import React, { useEffect } from 'react';
|
|
51
|
+
import { Channel, ChannelHeader, ChannelList, MessageList, Thread, useChannelActionContext, useChannelStateContext, useChatContext, Window, } from '../index';
|
|
52
|
+
import { ConnectedUser } from './utils';
|
|
53
|
+
var user1Id = import.meta.env.E2E_TEST_USER_1;
|
|
54
|
+
var user1Token = import.meta.env.E2E_TEST_USER_1_TOKEN;
|
|
55
|
+
var user2Id = import.meta.env.E2E_TEST_USER_2;
|
|
56
|
+
var user2Token = import.meta.env.E2E_TEST_USER_2_TOKEN;
|
|
57
|
+
var channelId = import.meta.env.E2E_LONG_MESSAGE_LISTS_CHANNEL;
|
|
58
|
+
if (!channelId || typeof channelId !== 'string') {
|
|
59
|
+
throw new Error('expected ADD_MESSAGE_CHANNEL');
|
|
60
|
+
}
|
|
61
|
+
var OtherUserControlButtons = function () {
|
|
62
|
+
var client = useChatContext().client;
|
|
63
|
+
var _a = useChannelStateContext(), channel = _a.channel, threadMessages = _a.threadMessages;
|
|
64
|
+
var lastMessage = channel.state.messages.slice(-1)[0];
|
|
65
|
+
return (React.createElement(React.Fragment, null,
|
|
66
|
+
React.createElement("button", { "data-testid": 'receive-reply', onClick: function () {
|
|
67
|
+
return channel.sendMessage({
|
|
68
|
+
parent_id: lastMessage.id,
|
|
69
|
+
text: 'Reply back',
|
|
70
|
+
});
|
|
71
|
+
} }, "Receive reply"),
|
|
72
|
+
React.createElement("button", { "data-testid": 'delete-other-last-reply', onClick: function () { return __awaiter(void 0, void 0, void 0, function () {
|
|
73
|
+
var lastReply;
|
|
74
|
+
return __generator(this, function (_a) {
|
|
75
|
+
switch (_a.label) {
|
|
76
|
+
case 0:
|
|
77
|
+
lastReply = threadMessages === null || threadMessages === void 0 ? void 0 : threadMessages.slice(-1)[0];
|
|
78
|
+
if (!lastReply) return [3 /*break*/, 2];
|
|
79
|
+
return [4 /*yield*/, client.deleteMessage(lastReply.id, true)];
|
|
80
|
+
case 1:
|
|
81
|
+
_a.sent();
|
|
82
|
+
_a.label = 2;
|
|
83
|
+
case 2: return [2 /*return*/];
|
|
84
|
+
}
|
|
85
|
+
});
|
|
86
|
+
}); } }, "Delete other user's last reply")));
|
|
87
|
+
};
|
|
88
|
+
// Sort in reverse order to avoid auto-selecting unread channel
|
|
89
|
+
var sort = { last_updated: 1 };
|
|
90
|
+
var Controls = function () {
|
|
91
|
+
var client = useChatContext().client;
|
|
92
|
+
var threadMessages = useChannelStateContext().threadMessages;
|
|
93
|
+
return (React.createElement("div", null,
|
|
94
|
+
React.createElement("button", { "data-testid": 'delete-last-reply', onClick: function () { return __awaiter(void 0, void 0, void 0, function () {
|
|
95
|
+
var lastReply;
|
|
96
|
+
return __generator(this, function (_a) {
|
|
97
|
+
switch (_a.label) {
|
|
98
|
+
case 0:
|
|
99
|
+
lastReply = threadMessages === null || threadMessages === void 0 ? void 0 : threadMessages.slice(-1)[0];
|
|
100
|
+
if (!lastReply) return [3 /*break*/, 2];
|
|
101
|
+
return [4 /*yield*/, client.deleteMessage(lastReply.id, true)];
|
|
102
|
+
case 1:
|
|
103
|
+
_a.sent();
|
|
104
|
+
_a.label = 2;
|
|
105
|
+
case 2: return [2 /*return*/];
|
|
106
|
+
}
|
|
107
|
+
});
|
|
108
|
+
}); } }, "Delete last reply")));
|
|
109
|
+
};
|
|
110
|
+
var SetThreadOpen = function () {
|
|
111
|
+
var openThread = useChannelActionContext().openThread;
|
|
112
|
+
var messages = useChannelStateContext().messages;
|
|
113
|
+
useEffect(function () {
|
|
114
|
+
if (messages) {
|
|
115
|
+
var lastMsg = messages.slice(-1)[0];
|
|
116
|
+
openThread(lastMsg, { preventDefault: function () { return null; } });
|
|
117
|
+
}
|
|
118
|
+
}, [messages]);
|
|
119
|
+
return null;
|
|
120
|
+
};
|
|
121
|
+
var OtherUserControls = function () {
|
|
122
|
+
var theOtherUserCredentials = document.location.search.match('user1')
|
|
123
|
+
? { token: user2Token, userId: user2Id }
|
|
124
|
+
: { token: user1Token, userId: user1Id };
|
|
125
|
+
return (React.createElement("div", { className: theOtherUserCredentials.userId },
|
|
126
|
+
React.createElement("style", null, "\n ." + theOtherUserCredentials.userId + " .str-chat-channel {\n max-height: 30px;\n display: inline-block;\n }\n ." + theOtherUserCredentials.userId + " .str-chat__container {\n height: 30px;\n }\n\n ." + theOtherUserCredentials.userId + " .messaging.str-chat .str-chat__thread {\n display: none;\n }\n "),
|
|
127
|
+
React.createElement(ConnectedUser, __assign({}, theOtherUserCredentials),
|
|
128
|
+
React.createElement("div", { style: { display: 'none' } },
|
|
129
|
+
React.createElement(ChannelList, { customActiveChannel: channelId, filters: { id: { $eq: channelId }, members: { $in: [theOtherUserCredentials.userId] } }, setActiveChannelOnMount: true, sort: sort })),
|
|
130
|
+
React.createElement("div", { style: { height: '30px' } },
|
|
131
|
+
React.createElement(Channel, null,
|
|
132
|
+
React.createElement(SetThreadOpen, null),
|
|
133
|
+
React.createElement(OtherUserControlButtons, null),
|
|
134
|
+
React.createElement(Thread, null))))));
|
|
135
|
+
};
|
|
136
|
+
var WrappedConnectedUser = function (_a) {
|
|
137
|
+
var token = _a.token, userId = _a.userId;
|
|
138
|
+
return (React.createElement("div", { style: { display: 'flex', flexDirection: 'column' } },
|
|
139
|
+
React.createElement("div", { className: userId },
|
|
140
|
+
React.createElement(ConnectedUser, { token: token, userId: userId },
|
|
141
|
+
React.createElement(ChannelList, { filters: { id: { $eq: channelId }, members: { $in: [userId] } }, setActiveChannelOnMount: false, sort: sort }),
|
|
142
|
+
React.createElement(Channel, null,
|
|
143
|
+
React.createElement(Window, null,
|
|
144
|
+
React.createElement(ChannelHeader, null),
|
|
145
|
+
React.createElement(MessageList, null),
|
|
146
|
+
React.createElement(Controls, null)),
|
|
147
|
+
React.createElement(Thread, null)))),
|
|
148
|
+
React.createElement(OtherUserControls, null)));
|
|
149
|
+
};
|
|
150
|
+
export var User1 = function () {
|
|
151
|
+
if (!user1Id || typeof user1Id !== 'string') {
|
|
152
|
+
throw new Error('expected TEST_USER_1');
|
|
153
|
+
}
|
|
154
|
+
if (!user1Token || typeof user1Token !== 'string') {
|
|
155
|
+
throw new Error('expected TEST_USER_1_TOKEN');
|
|
156
|
+
}
|
|
157
|
+
return React.createElement(WrappedConnectedUser, { token: user1Token, userId: user1Id });
|
|
158
|
+
};
|
|
159
|
+
export var User2 = function () {
|
|
160
|
+
if (!user2Id || typeof user2Id !== 'string') {
|
|
161
|
+
throw new Error('expected TEST_USER_2');
|
|
162
|
+
}
|
|
163
|
+
if (!user2Token || typeof user2Token !== 'string') {
|
|
164
|
+
throw new Error('expected TEST_USER_2_TOKEN');
|
|
165
|
+
}
|
|
166
|
+
return React.createElement(WrappedConnectedUser, { token: user2Token, userId: user2Id });
|
|
167
|
+
};
|
package/dist/stories/utils.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { PropsWithChildren } from 'react';
|
|
2
|
-
import
|
|
2
|
+
import { DefaultGenerics } from 'stream-chat';
|
|
3
3
|
export declare const apiKey: string;
|
|
4
4
|
declare type LocalAttachmentType = Record<string, unknown>;
|
|
5
5
|
declare type LocalChannelType = Record<string, unknown>;
|
|
@@ -20,8 +20,7 @@ export declare type StreamChatGenerics = {
|
|
|
20
20
|
export declare type ConnectedUserProps = PropsWithChildren<{
|
|
21
21
|
token: string;
|
|
22
22
|
userId: string;
|
|
23
|
-
client?: StreamChat;
|
|
24
23
|
}>;
|
|
25
|
-
export declare const ConnectedUser: ({ children,
|
|
24
|
+
export declare const ConnectedUser: <SCG extends DefaultGenerics = StreamChatGenerics>({ children, token, userId, }: ConnectedUserProps) => JSX.Element;
|
|
26
25
|
export {};
|
|
27
26
|
//# sourceMappingURL=utils.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"utils.d.ts","sourceRoot":"","sources":["../../src/stories/utils.tsx"],"names":[],"mappings":"AAAA,OAAc,EAAE,iBAAiB,EAAuB,MAAM,OAAO,CAAC;AAEtE,OAAO,
|
|
1
|
+
{"version":3,"file":"utils.d.ts","sourceRoot":"","sources":["../../src/stories/utils.tsx"],"names":[],"mappings":"AAAA,OAAc,EAAE,iBAAiB,EAAuB,MAAM,OAAO,CAAC;AAEtE,OAAO,EAAE,eAAe,EAAqB,MAAM,aAAa,CAAC;AAMjE,eAAO,MAAM,MAAM,QAAS,CAAC;AAE7B,aAAK,mBAAmB,GAAG,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;AACnD,aAAK,gBAAgB,GAAG,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;AAChD,aAAK,gBAAgB,GAAG,MAAM,CAAC;AAC/B,aAAK,cAAc,GAAG,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;AAC9C,aAAK,gBAAgB,GAAG,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;AAChD,aAAK,iBAAiB,GAAG,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;AACjD,aAAK,aAAa,GAAG,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;AAE7C,oBAAY,kBAAkB,GAAG;IAC/B,cAAc,EAAE,mBAAmB,CAAC;IACpC,WAAW,EAAE,gBAAgB,CAAC;IAC9B,WAAW,EAAE,gBAAgB,CAAC;IAC9B,SAAS,EAAE,cAAc,CAAC;IAC1B,WAAW,EAAE,gBAAgB,CAAC;IAC9B,YAAY,EAAE,iBAAiB,CAAC;IAChC,QAAQ,EAAE,aAAa,CAAC;CACzB,CAAC;AAEF,oBAAY,kBAAkB,GAAG,iBAAiB,CAAC;IACjD,KAAK,EAAE,MAAM,CAAC;IACd,MAAM,EAAE,MAAM,CAAC;CAChB,CAAC,CAAC;AAEH,eAAO,MAAM,aAAa,mFAIvB,kBAAkB,gBA+BpB,CAAC"}
|
package/dist/stories/utils.js
CHANGED
|
@@ -1,32 +1,32 @@
|
|
|
1
1
|
import React, { useEffect, useState } from 'react';
|
|
2
2
|
import { Chat } from '../';
|
|
3
|
+
import { StreamChat } from 'stream-chat';
|
|
3
4
|
var appKey = import.meta.env.E2E_APP_KEY;
|
|
4
5
|
if (!appKey || typeof appKey !== 'string') {
|
|
5
6
|
throw new Error('expected APP_KEY');
|
|
6
7
|
}
|
|
7
8
|
export var apiKey = appKey;
|
|
8
|
-
// wait for disconnect to happen since there's only one shared
|
|
9
|
-
// client and two separate Chat components using it to prevent crashes
|
|
10
|
-
var sharedPromise = Promise.resolve();
|
|
11
9
|
export var ConnectedUser = function (_a) {
|
|
12
|
-
var children = _a.children,
|
|
13
|
-
var _b = useState(
|
|
10
|
+
var children = _a.children, token = _a.token, userId = _a.userId;
|
|
11
|
+
var _b = useState(null), client = _b[0], setClient = _b[1];
|
|
14
12
|
useEffect(function () {
|
|
15
|
-
|
|
13
|
+
var c = new StreamChat(apiKey);
|
|
16
14
|
var handleConnectionChange = function (_a) {
|
|
17
15
|
var _b = _a.online, online = _b === void 0 ? false : _b;
|
|
18
|
-
|
|
16
|
+
if (!online)
|
|
17
|
+
console.log('connection lost');
|
|
18
|
+
setClient(c);
|
|
19
19
|
};
|
|
20
|
-
|
|
20
|
+
c.on('connection.changed', handleConnectionChange);
|
|
21
|
+
c.connectUser({ id: userId }, token);
|
|
21
22
|
return function () {
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
sharedPromise = (_a = client === null || client === void 0 ? void 0 : client.disconnectUser()) !== null && _a !== void 0 ? _a : Promise.resolve();
|
|
23
|
+
c.off('connection.changed', handleConnectionChange);
|
|
24
|
+
c.disconnectUser().then(function () { return console.log('connection closed'); });
|
|
25
25
|
};
|
|
26
|
-
}, []);
|
|
27
|
-
if (!
|
|
26
|
+
}, [userId, token]);
|
|
27
|
+
if (!client) {
|
|
28
28
|
return React.createElement("p", null,
|
|
29
|
-
"
|
|
29
|
+
"Waiting for connection to be established with user: ",
|
|
30
30
|
userId,
|
|
31
31
|
"...");
|
|
32
32
|
}
|
package/dist/version.d.ts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export declare const version = "8.1.
|
|
1
|
+
export declare const version = "8.1.3";
|
|
2
2
|
//# sourceMappingURL=version.d.ts.map
|
package/dist/version.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export var version = '8.1.
|
|
1
|
+
export var version = '8.1.3';
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "stream-chat-react",
|
|
3
|
-
"version": "8.1.
|
|
3
|
+
"version": "8.1.3",
|
|
4
4
|
"description": "React components to create chat conversations or livestream style chat",
|
|
5
5
|
"author": "GetStream",
|
|
6
6
|
"homepage": "https://getstream.io/chat/",
|
|
@@ -56,7 +56,7 @@
|
|
|
56
56
|
},
|
|
57
57
|
"optionalDependencies": {
|
|
58
58
|
"@stream-io/transliterate": "^1.5.5",
|
|
59
|
-
"mml-react": "^0.4.
|
|
59
|
+
"mml-react": "^0.4.5"
|
|
60
60
|
},
|
|
61
61
|
"peerDependencies": {
|
|
62
62
|
"react": "^17.0.0 || ^16.8.0",
|
|
@@ -81,7 +81,7 @@
|
|
|
81
81
|
"@commitlint/cli": "^16.2.3",
|
|
82
82
|
"@commitlint/config-conventional": "^16.2.1",
|
|
83
83
|
"@ladle/react": "^0.11.0",
|
|
84
|
-
"@playwright/test": "^1.
|
|
84
|
+
"@playwright/test": "^1.22.0",
|
|
85
85
|
"@rollup/plugin-babel": "^5.2.1",
|
|
86
86
|
"@rollup/plugin-image": "^2.1.1",
|
|
87
87
|
"@rollup/plugin-json": "^4.1.0",
|
|
@@ -89,6 +89,7 @@
|
|
|
89
89
|
"@rollup/plugin-replace": "^2.3.4",
|
|
90
90
|
"@rollup/plugin-typescript": "8.2.1",
|
|
91
91
|
"@semantic-release/changelog": "^6.0.1",
|
|
92
|
+
"@semantic-release/git": "^10.0.1",
|
|
92
93
|
"@stream-io/rollup-plugin-node-builtins": "^2.1.5",
|
|
93
94
|
"@testing-library/jest-dom": "5.11.6",
|
|
94
95
|
"@testing-library/react": "^11.2.2",
|
|
@@ -182,7 +183,7 @@
|
|
|
182
183
|
},
|
|
183
184
|
"scripts": {
|
|
184
185
|
"analyze": "yarn build -- --stats && webpack-bundle-analyzer build/bundle-stats.json",
|
|
185
|
-
"build": "rm -rf dist && mkdir -p dist/assets
|
|
186
|
+
"build": "rm -rf dist && mkdir -p dist/assets && yarn --silent copy-version && yarn build-translations && yarn types && yarn bundle",
|
|
186
187
|
"bundle": "rollup -c",
|
|
187
188
|
"bundle-size": "BUNDLE_SIZE=true yarn bundle",
|
|
188
189
|
"build-translations": "i18next",
|
|
@@ -202,7 +203,8 @@
|
|
|
202
203
|
"semantic-release": "semantic-release",
|
|
203
204
|
"browse-examples": "ladle serve",
|
|
204
205
|
"e2e": "playwright test",
|
|
205
|
-
"e2e-fixtures": "node e2e/fixtures.mjs"
|
|
206
|
+
"e2e-fixtures": "node e2e/fixtures.mjs",
|
|
207
|
+
"e2e-container": "./e2e/scripts/run_in_container.sh"
|
|
206
208
|
},
|
|
207
209
|
"resolutions": {
|
|
208
210
|
"ast-types": "^0.14.0"
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
<svg width="14" height="14" xmlns="http://www.w3.org/2000/svg"><path d="M7 0a7 7 0 1 0 0 14A7 7 0 0 0 7 0zm.875 10.938a.438.438 0 0 1-.438.437h-.875a.438.438 0 0 1-.437-.438v-.874c0-.242.196-.438.438-.438h.875c.241 0 .437.196.437.438v.874zm0-2.626a.438.438 0 0 1-.438.438h-.875a.438.438 0 0 1-.437-.438v-5.25c0-.241.196-.437.438-.437h.875c.241 0 .437.196.437.438v5.25z" fill="#EA152F" fill-rule="evenodd"/></svg>
|
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
<?xml version="1.0" encoding="UTF-8"?>
|
|
2
|
-
<svg width="78px" height="78px" viewBox="0 0 78 78" version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink">
|
|
3
|
-
<!-- Generator: Sketch 52.6 (67491) - http://www.bohemiancoding.com/sketch -->
|
|
4
|
-
<title>Combined Shape</title>
|
|
5
|
-
<desc>Created with Sketch.</desc>
|
|
6
|
-
<g id="Interactions" stroke="none" stroke-width="1" fill="none" fill-rule="evenodd">
|
|
7
|
-
<g id="Connection-Error-_-Connectivity" transform="translate(-270.000000, -30.000000)" fill="#CF1F25">
|
|
8
|
-
<g id="109-network-connection" transform="translate(270.000000, 30.000000)">
|
|
9
|
-
<path d="M66.4609744,11.414231 C81.6225232,26.5757798 81.6225232,51.157545 66.4609744,66.3188467 C51.2994256,81.4803954 26.7176604,81.4803954 11.5563587,66.3188467 C-3.60519004,51.1572979 -3.60519004,26.5755327 11.5563587,11.414231 C26.7179075,-3.74731776 51.2996727,-3.74731776 66.4609744,11.414231 Z M54.7853215,45.8823776 L54.7853215,40.5882574 C54.7853215,39.613638 53.9952341,38.8235506 53.0206147,38.8235506 L44.9576695,38.8235506 L41.428256,42.3529641 L51.255555,42.3529641 L51.255555,45.8823776 L54.7853215,45.8823776 Z M40.6659027,43.1153174 L37.8988425,45.8823776 L40.6659027,45.8823776 L40.6659027,43.1153174 Z M51.1764962,56.4702653 L58.2353232,56.4702653 C59.2099355,56.4702653 60.00003,55.6801708 60.00003,54.7055585 L60.00003,51.176145 C60.00003,50.2015327 59.2099355,49.4114382 58.2353232,49.4114382 L51.1764962,49.4114382 C50.2018839,49.4114382 49.4117894,50.2015327 49.4117894,51.176145 L49.4117894,54.7055585 C49.4117894,55.6801708 50.2018839,56.4702653 51.1764962,56.4702653 Z M35.2941353,56.4702653 L42.3529624,56.4702653 C43.3275746,56.4702653 44.1176691,55.6801708 44.1176691,54.7055585 L44.1176691,51.176145 C44.1176691,50.2015327 43.3275746,49.4114382 42.3529624,49.4114382 L35.2941353,49.4114382 C34.319523,49.4114382 33.5294285,50.2015327 33.5294285,51.176145 L33.5294285,54.7055585 C33.5294285,55.6801708 34.319523,56.4702653 35.2941353,56.4702653 Z M56.6964989,19.0874231 C56.007381,18.3985134 54.8903216,18.3985134 54.2012036,19.087423 L45.882376,27.4062507 L45.882376,19.4117761 C45.882376,18.4371568 45.0922885,17.6470693 44.1176692,17.6470693 L33.5294286,17.6470693 C32.5548092,17.6470694 31.7647218,18.4371568 31.7647218,19.4117761 L31.7647218,30.0000167 C31.7647219,30.9746363 32.5548092,31.7647237 33.5294285,31.7647237 L41.5239031,31.7647237 L34.4650761,38.8235508 L24.7058947,38.8235508 C23.7312753,38.8235508 22.9411879,39.6136382 22.9411879,40.5882575 L22.9411879,45.8823778 L26.4706014,45.8823778 L26.4706014,42.3529643 L30.9356624,42.3529643 L23.8768354,49.4117914 L19.4117743,49.4117914 C18.4371549,49.4117914 17.6470675,50.2018788 17.6470675,51.1764981 L17.6470675,54.7059117 C17.6504049,54.9674302 17.7129076,55.2248042 17.8298886,55.4587302 L16.4456526,56.8429662 C15.7446193,57.5200453 15.7252005,58.6372282 16.4022825,59.3382615 C17.0793616,60.0392948 18.1965445,60.0587136 18.8975778,59.3816316 C18.9122847,59.3674273 18.9267436,59.3529684 18.940948,59.3382615 L56.6964963,21.5830662 C57.3856425,20.8939094 57.3856425,19.7765747 56.6964963,19.0874179 Z" id="Combined-Shape"></path>
|
|
10
|
-
</g>
|
|
11
|
-
</g>
|
|
12
|
-
</g>
|
|
13
|
-
</svg>
|
|
@@ -1,20 +0,0 @@
|
|
|
1
|
-
<?xml version="1.0" encoding="UTF-8"?>
|
|
2
|
-
<svg width="25px" height="30px" viewBox="0 0 25 30" version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink">
|
|
3
|
-
<!-- Generator: Sketch 52.6 (67491) - http://www.bohemiancoding.com/sketch -->
|
|
4
|
-
<title>file icon</title>
|
|
5
|
-
<desc>Created with Sketch.</desc>
|
|
6
|
-
<g id="Team-Chat" stroke="none" stroke-width="1" fill="none" fill-rule="evenodd">
|
|
7
|
-
<g id="LIGHT_02-Team-Chat" transform="translate(-399.000000, -2328.000000)">
|
|
8
|
-
<g id="Channel-Conversations" transform="translate(300.000000, 0.000000)">
|
|
9
|
-
<g id="ConversationMessageView" transform="translate(40.000000, 2239.000000)">
|
|
10
|
-
<g id="MessageContent_file" transform="translate(49.000000, 83.000000)">
|
|
11
|
-
<g id="file-icon" transform="translate(10.000000, 6.000000)">
|
|
12
|
-
<path d="M0,1.99161703 C0,0.891677316 0.889763236,0 2.00359486,0 L22.9964051,0 C24.10296,0 25,0.89784041 25,1.99161703 L25,28.008383 C25,29.1083227 24.1102368,30 22.9964051,30 L2.00359486,30 C0.897039974,30 0,29.1021596 0,28.008383 L0,1.99161703 Z" id="placeholder" fill="#D1D1D1"></path>
|
|
13
|
-
<path d="M5,5 L20,5 L20,7 L5,7 L5,5 Z M5,9 L20,9 L20,11 L5,11 L5,9 Z M5,13 L20,13 L20,15 L5,15 L5,13 Z M5,17 L12,17 L12,19 L5,19 L5,17 Z" id="lines" fill="#FFFFFF"></path>
|
|
14
|
-
</g>
|
|
15
|
-
</g>
|
|
16
|
-
</g>
|
|
17
|
-
</g>
|
|
18
|
-
</g>
|
|
19
|
-
</g>
|
|
20
|
-
</svg>
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
<svg width="8" height="5" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink"><defs><path id="b" d="M.667.667L4 4 7.333.667z"/><filter x="-7.5%" y="-15%" width="115%" height="160%" filterUnits="objectBoundingBox" id="a"><feOffset dy="1" in="SourceAlpha" result="shadowOffsetOuter1"/><feComposite in="shadowOffsetOuter1" in2="SourceAlpha" operator="out" result="shadowOffsetOuter1"/><feColorMatrix values="0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0.685858243 0" in="shadowOffsetOuter1"/></filter></defs><g fill="none" fill-rule="evenodd"><use fill="#000" filter="url(#a)" xlink:href="#b"/><use fill-opacity=".7" fill="#FFF" xlink:href="#b"/></g></svg>
|