stream-chat-react 10.1.2 → 10.3.0
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 +253 -72
- package/dist/browser.full-bundle.js.map +1 -1
- package/dist/browser.full-bundle.min.js +5 -5
- package/dist/browser.full-bundle.min.js.map +1 -1
- package/dist/components/Attachment/AttachmentContainer.d.ts.map +1 -1
- package/dist/components/Attachment/AttachmentContainer.js +67 -15
- package/dist/components/Attachment/attachment-sizing.d.ts +9 -0
- package/dist/components/Attachment/attachment-sizing.d.ts.map +1 -0
- package/dist/components/Attachment/attachment-sizing.js +72 -0
- package/dist/components/Channel/Channel.d.ts +7 -1
- package/dist/components/Channel/Channel.d.ts.map +1 -1
- package/dist/components/Channel/Channel.js +2 -1
- package/dist/components/Channel/hooks/useCreateChannelStateContext.d.ts.map +1 -1
- package/dist/components/Channel/hooks/useCreateChannelStateContext.js +5 -1
- package/dist/components/ChannelList/ChannelList.d.ts.map +1 -1
- package/dist/components/ChannelList/ChannelList.js +2 -2
- package/dist/components/ChannelList/ChannelListMessenger.js +2 -2
- package/dist/components/Gallery/Gallery.d.ts +7 -2
- package/dist/components/Gallery/Gallery.d.ts.map +1 -1
- package/dist/components/Gallery/Gallery.js +16 -5
- package/dist/components/Gallery/Image.d.ts +4 -0
- package/dist/components/Gallery/Image.d.ts.map +1 -1
- package/dist/components/Gallery/Image.js +3 -3
- package/dist/components/InfiniteScrollPaginator/InfiniteScroll.d.ts +19 -4
- package/dist/components/InfiniteScrollPaginator/InfiniteScroll.d.ts.map +1 -1
- package/dist/components/InfiniteScrollPaginator/InfiniteScroll.js +28 -6
- package/dist/components/LoadMore/LoadMoreButton.d.ts +7 -2
- package/dist/components/LoadMore/LoadMoreButton.d.ts.map +1 -1
- package/dist/components/LoadMore/LoadMoreButton.js +9 -4
- package/dist/components/LoadMore/LoadMorePaginator.d.ts +2 -7
- package/dist/components/LoadMore/LoadMorePaginator.d.ts.map +1 -1
- package/dist/components/LoadMore/LoadMorePaginator.js +8 -3
- package/dist/components/Message/hooks/useUserRole.d.ts +1 -1
- package/dist/components/Message/hooks/useUserRole.d.ts.map +1 -1
- package/dist/components/Message/hooks/useUserRole.js +5 -5
- package/dist/components/MessageInput/hooks/useFileUploads.d.ts.map +1 -1
- package/dist/components/MessageInput/hooks/useFileUploads.js +1 -0
- package/dist/components/MessageInput/hooks/useMessageInputState.d.ts +2 -0
- package/dist/components/MessageInput/hooks/useMessageInputState.d.ts.map +1 -1
- package/dist/components/MessageInput/hooks/useMessageInputState.js +2 -1
- package/dist/components/MessageInput/hooks/useSubmitHandler.d.ts.map +1 -1
- package/dist/components/MessageInput/hooks/useSubmitHandler.js +1 -0
- package/dist/components/MessageList/MessageList.d.ts.map +1 -1
- package/dist/components/MessageList/MessageList.js +2 -3
- package/dist/components/MessageList/VirtualizedMessageList.d.ts.map +1 -1
- package/dist/components/MessageList/VirtualizedMessageList.js +0 -1
- package/dist/components/MessageList/hooks/useMessageListElements.d.ts +0 -1
- package/dist/components/MessageList/hooks/useMessageListElements.d.ts.map +1 -1
- package/dist/components/MessageList/hooks/useMessageListElements.js +2 -3
- package/dist/components/MessageList/hooks/useScrollLocationLogic.d.ts +0 -1
- package/dist/components/MessageList/hooks/useScrollLocationLogic.d.ts.map +1 -1
- package/dist/components/MessageList/hooks/useScrollLocationLogic.js +0 -10
- package/dist/components/Reactions/SimpleReactionsList.d.ts.map +1 -1
- package/dist/components/Reactions/SimpleReactionsList.js +26 -6
- package/dist/components/Thread/Thread.d.ts.map +1 -1
- package/dist/components/Thread/Thread.js +7 -2
- package/dist/context/ChannelStateContext.d.ts +5 -2
- package/dist/context/ChannelStateContext.d.ts.map +1 -1
- package/dist/css/index.css +1 -1
- package/dist/css/index.css.map +1 -1
- package/dist/css/v2/index.css +1 -1
- package/dist/css/v2/index.css.map +1 -1
- package/dist/css/v2/index.layout.css +1 -1
- package/dist/css/v2/index.layout.css.map +1 -1
- package/dist/index.cjs.js +252 -71
- package/dist/index.cjs.js.map +1 -1
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +1 -0
- package/dist/scss/Attachment.scss +44 -17
- package/dist/scss/Audio.scss +1 -0
- package/dist/scss/ChannelList.scss +14 -0
- package/dist/scss/ChannelSearch.scss +8 -8
- package/dist/scss/Message.scss +28 -11
- package/dist/scss/v2/AttachmentList/AttachmentList-layout.scss +33 -19
- package/dist/scss/v2/ChannelList/ChannelList-layout.scss +14 -0
- package/dist/scss/v2/ChannelSearch/ChannelSearch-layout.scss +68 -51
- package/dist/scss/v2/ChannelSearch/ChannelSearch-theme.scss +48 -0
- package/dist/scss/v2/Message/Message-layout.scss +12 -0
- package/dist/scss/v2/Message/Message-theme.scss +20 -0
- package/dist/scss/v2/MessageList/MessageList-layout.scss +1 -4
- package/dist/scss/v2/MessageList/VirtualizedMessageList-layout.scss +21 -0
- package/dist/scss/v2/MessageList/VirtualizedMessageList-theme.scss +9 -0
- package/dist/scss/v2/Notification/NotificationList-theme.scss +2 -2
- package/dist/scss/v2/Tooltip/Tooltip-layout.scss +1 -1
- package/dist/scss/v2/_utils.scss +8 -0
- package/dist/stories/attachment-sizing.stories.d.ts +2 -0
- package/dist/stories/attachment-sizing.stories.d.ts.map +1 -0
- package/dist/stories/attachment-sizing.stories.js +179 -0
- package/dist/types/types.d.ts +19 -2
- package/dist/types/types.d.ts.map +1 -1
- package/dist/utils/deprecationWarning.d.ts +2 -0
- package/dist/utils/deprecationWarning.d.ts.map +1 -0
- package/dist/utils/deprecationWarning.js +12 -0
- package/dist/version.d.ts +1 -1
- package/dist/version.js +1 -1
- package/package.json +3 -3
package/dist/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,cAAc,cAAc,CAAC;AAC7B,cAAc,WAAW,CAAC;AAC1B,cAAc,QAAQ,CAAC;
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,cAAc,cAAc,CAAC;AAC7B,cAAc,WAAW,CAAC;AAC1B,cAAc,QAAQ,CAAC;AAEvB,cAAc,SAAS,CAAC"}
|
package/dist/index.js
CHANGED
|
@@ -1,16 +1,30 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
1
|
+
@mixin clamped-height-from-original-image-dimensions($max-height-css-var, $max-width-css-var) {
|
|
2
|
+
height: min(
|
|
3
|
+
var(#{$max-height-css-var}),
|
|
4
|
+
min(var(#{$max-width-css-var}, 1000000) / var(--original-width, 1000000), 1px) *
|
|
5
|
+
var(--original-height, 1000000)
|
|
6
|
+
);
|
|
3
7
|
}
|
|
4
8
|
|
|
5
|
-
|
|
9
|
+
.str-chat__attachment,
|
|
10
|
+
.str-chat__message-attachment {
|
|
11
|
+
--attachment-max-width: 450px;
|
|
12
|
+
--video-width: 300px;
|
|
13
|
+
|
|
14
|
+
max-width: var(--attachment-max-width);
|
|
15
|
+
}
|
|
6
16
|
|
|
7
|
-
.str-chat__message-attachment--video:not(.str-chat__message-attachment--card) {
|
|
8
|
-
width:
|
|
17
|
+
.str-chat__message-attachment.str-chat__message-attachment--video:not(.str-chat__message-attachment--card) {
|
|
18
|
+
--attachment-max-width: var(--video-width);
|
|
19
|
+
width: var(--video-width);
|
|
9
20
|
}
|
|
10
21
|
|
|
11
22
|
.str-chat__player-wrapper {
|
|
12
23
|
position: relative;
|
|
13
24
|
padding-top: 56.25%; /* Player ratio: 100 / (1280 / 720) */
|
|
25
|
+
display: flex;
|
|
26
|
+
flex-direction: column;
|
|
27
|
+
|
|
14
28
|
.react-player,
|
|
15
29
|
.str-chat__video-angular {
|
|
16
30
|
position: absolute;
|
|
@@ -18,23 +32,33 @@ $video-width: 300px;
|
|
|
18
32
|
left: 0;
|
|
19
33
|
width: 100%;
|
|
20
34
|
height: 100%;
|
|
35
|
+
min-height: 0;
|
|
36
|
+
max-height: 100%;
|
|
21
37
|
}
|
|
22
38
|
}
|
|
23
39
|
|
|
24
40
|
.str-chat__message-attachment-dynamic-size {
|
|
25
|
-
|
|
41
|
+
--video-max-height: 300px;
|
|
26
42
|
|
|
27
|
-
max-height:
|
|
43
|
+
max-height: var(--video-max-height);
|
|
28
44
|
|
|
29
45
|
.str-chat__player-wrapper {
|
|
46
|
+
@include clamped-height-from-original-image-dimensions(
|
|
47
|
+
'--video-max-height',
|
|
48
|
+
'--attachment-max-width'
|
|
49
|
+
);
|
|
30
50
|
padding-top: 0;
|
|
31
51
|
position: static;
|
|
52
|
+
// CDN resize requires to have max-height/height and max-width set on this element - React
|
|
53
|
+
max-height: var(--video-max-height);
|
|
54
|
+
max-width: var(--attachment-max-width);
|
|
32
55
|
|
|
33
|
-
.str-chat__video-angular
|
|
56
|
+
.str-chat__video-angular,
|
|
57
|
+
.react-player {
|
|
34
58
|
position: static;
|
|
35
|
-
// CDN resize requires to have max-height/height and max-width set on this element
|
|
36
|
-
max-height:
|
|
37
|
-
max-width:
|
|
59
|
+
// CDN resize requires to have max-height/height and max-width set on this element - Angular
|
|
60
|
+
max-height: var(--video-max-height);
|
|
61
|
+
max-width: var(--attachment-max-width);
|
|
38
62
|
}
|
|
39
63
|
}
|
|
40
64
|
}
|
|
@@ -52,8 +76,8 @@ $video-width: 300px;
|
|
|
52
76
|
|
|
53
77
|
.str-chat__message {
|
|
54
78
|
&-attachment {
|
|
79
|
+
--attachment-max-width: 375px;
|
|
55
80
|
width: 100%;
|
|
56
|
-
max-width: 375px;
|
|
57
81
|
|
|
58
82
|
border-radius: var(--border-radius);
|
|
59
83
|
padding: var(--xs-m) auto var(--xs-m) 0;
|
|
@@ -77,7 +101,7 @@ $video-width: 300px;
|
|
|
77
101
|
|
|
78
102
|
.str-chat__message-team.thread-list {
|
|
79
103
|
.str-chat__message-attachment {
|
|
80
|
-
max-width: 200px;
|
|
104
|
+
--attachment-max-width: 200px;
|
|
81
105
|
}
|
|
82
106
|
}
|
|
83
107
|
|
|
@@ -185,9 +209,9 @@ $video-width: 300px;
|
|
|
185
209
|
}
|
|
186
210
|
|
|
187
211
|
&--image {
|
|
188
|
-
height:
|
|
189
|
-
max-height:
|
|
190
|
-
max-width:
|
|
212
|
+
--image-max-height: 300px;
|
|
213
|
+
max-height: var(--image-max-height);
|
|
214
|
+
max-width: var(--attachment-max-width);
|
|
191
215
|
border-radius: 0;
|
|
192
216
|
|
|
193
217
|
&:hover {
|
|
@@ -195,7 +219,10 @@ $video-width: 300px;
|
|
|
195
219
|
}
|
|
196
220
|
|
|
197
221
|
img {
|
|
198
|
-
height
|
|
222
|
+
@include clamped-height-from-original-image-dimensions(
|
|
223
|
+
'--image-max-height',
|
|
224
|
+
'--attachment-max-width'
|
|
225
|
+
);
|
|
199
226
|
width: auto;
|
|
200
227
|
max-height: inherit;
|
|
201
228
|
display: block;
|
package/dist/scss/Audio.scss
CHANGED
|
@@ -125,3 +125,17 @@
|
|
|
125
125
|
}
|
|
126
126
|
}
|
|
127
127
|
}
|
|
128
|
+
|
|
129
|
+
.str-chat__channel-list.str-chat__channel-list-react {
|
|
130
|
+
overflow: hidden;
|
|
131
|
+
|
|
132
|
+
.str-chat__channel-list-messenger-react {
|
|
133
|
+
overflow: hidden;
|
|
134
|
+
padding-bottom: var(--sm-p);
|
|
135
|
+
|
|
136
|
+
.str-chat__channel-list-messenger-react__main {
|
|
137
|
+
overflow-y: auto;
|
|
138
|
+
height: 100%;
|
|
139
|
+
}
|
|
140
|
+
}
|
|
141
|
+
}
|
|
@@ -1,14 +1,15 @@
|
|
|
1
1
|
.str-chat__channel-search {
|
|
2
2
|
--channel-search-input-height: 30px;
|
|
3
3
|
|
|
4
|
-
padding: var(--md-p)
|
|
4
|
+
padding: var(--md-p);
|
|
5
5
|
display: flex;
|
|
6
|
+
flex-direction: column;
|
|
6
7
|
align-items: center;
|
|
7
8
|
position: relative;
|
|
8
9
|
background: var(--grey-gainsboro);
|
|
9
10
|
|
|
10
11
|
input {
|
|
11
|
-
|
|
12
|
+
width: 100%;
|
|
12
13
|
background: var(--grey-whisper);
|
|
13
14
|
border: 1px solid transparent;
|
|
14
15
|
outline: none;
|
|
@@ -31,9 +32,7 @@
|
|
|
31
32
|
}
|
|
32
33
|
|
|
33
34
|
&-container {
|
|
34
|
-
|
|
35
|
-
width: 300px;
|
|
36
|
-
z-index: 2;
|
|
35
|
+
|
|
37
36
|
padding: 8px;
|
|
38
37
|
|
|
39
38
|
&-searching {
|
|
@@ -69,7 +68,10 @@
|
|
|
69
68
|
&-container.popup {
|
|
70
69
|
border-radius: var(--border-radius-md);
|
|
71
70
|
background: var(--white-smoke);
|
|
71
|
+
position: absolute;
|
|
72
|
+
z-index: 2;
|
|
72
73
|
left: 0;
|
|
74
|
+
right: 0;
|
|
73
75
|
top: calc(var(--channel-search-input-height) + 40px);
|
|
74
76
|
box-shadow: 0 7px 9px 0 var(--border), 0 1px 0 0 var(--border);
|
|
75
77
|
border: 1px solid var(--border);
|
|
@@ -86,10 +88,8 @@
|
|
|
86
88
|
}
|
|
87
89
|
|
|
88
90
|
&-container.inline {
|
|
89
|
-
|
|
90
|
-
right: 0;
|
|
91
|
+
width: 100%;
|
|
91
92
|
background: var(--grey-gainsboro);
|
|
92
|
-
height: calc(100vh - 60px);
|
|
93
93
|
|
|
94
94
|
.str-chat__channel-search-result {
|
|
95
95
|
&:hover {
|
package/dist/scss/Message.scss
CHANGED
|
@@ -8,6 +8,24 @@
|
|
|
8
8
|
*/
|
|
9
9
|
.str-chat__message-inner {
|
|
10
10
|
min-width: 0;
|
|
11
|
+
|
|
12
|
+
.str-chat__translation-notice {
|
|
13
|
+
button {
|
|
14
|
+
cursor: pointer;
|
|
15
|
+
padding: 0.25rem 0;
|
|
16
|
+
margin: 0;
|
|
17
|
+
font-size: 14px;
|
|
18
|
+
line-height: 16px;
|
|
19
|
+
color: var(--lighten-grey);
|
|
20
|
+
border: none;
|
|
21
|
+
background: none;
|
|
22
|
+
|
|
23
|
+
&:active,
|
|
24
|
+
&:hover {
|
|
25
|
+
background: var(--grey-whisper);
|
|
26
|
+
}
|
|
27
|
+
}
|
|
28
|
+
}
|
|
11
29
|
}
|
|
12
30
|
|
|
13
31
|
.quoted-message {
|
|
@@ -417,11 +435,11 @@
|
|
|
417
435
|
}
|
|
418
436
|
|
|
419
437
|
&-attachment {
|
|
438
|
+
--attachment-max-width: 480px;
|
|
439
|
+
|
|
420
440
|
&--img {
|
|
421
441
|
width: 100%;
|
|
422
|
-
max-width: 480px;
|
|
423
442
|
display: block;
|
|
424
|
-
height: inherit;
|
|
425
443
|
cursor: -moz-zoom-in;
|
|
426
444
|
cursor: -webkit-zoom-in;
|
|
427
445
|
cursor: zoom-in;
|
|
@@ -525,7 +543,6 @@
|
|
|
525
543
|
// CDN resize requires max-width to be set on this element
|
|
526
544
|
max-width: inherit;
|
|
527
545
|
display: block;
|
|
528
|
-
height: inherit;
|
|
529
546
|
object-fit: cover;
|
|
530
547
|
border: none;
|
|
531
548
|
}
|
|
@@ -831,8 +848,8 @@
|
|
|
831
848
|
flex-direction: row-reverse;
|
|
832
849
|
}
|
|
833
850
|
|
|
834
|
-
.str-chat__message-attachment
|
|
835
|
-
max-width: 460px;
|
|
851
|
+
.str-chat__message-attachment {
|
|
852
|
+
--attachment-max-width: 460px;
|
|
836
853
|
}
|
|
837
854
|
|
|
838
855
|
&-text-inner {
|
|
@@ -1180,20 +1197,20 @@
|
|
|
1180
1197
|
}
|
|
1181
1198
|
|
|
1182
1199
|
@media screen and (max-width: 375px) {
|
|
1183
|
-
.str-chat__message .str-chat__message-attachment
|
|
1184
|
-
max-width: 235px;
|
|
1200
|
+
.str-chat__message .str-chat__message-attachment {
|
|
1201
|
+
--attachment-max-width: 235px;
|
|
1185
1202
|
}
|
|
1186
1203
|
}
|
|
1187
1204
|
|
|
1188
1205
|
@media screen and (max-width: 414px) {
|
|
1189
|
-
.str-chat__message .str-chat__message-attachment
|
|
1190
|
-
max-width:
|
|
1206
|
+
.str-chat__message .str-chat__message-attachment {
|
|
1207
|
+
--attachment-max-width: 235px;
|
|
1191
1208
|
}
|
|
1192
1209
|
}
|
|
1193
1210
|
|
|
1194
1211
|
@media only screen and (device-width: 375px) and (-webkit-device-pixel-ratio: 3) {
|
|
1195
|
-
.str-chat__message .str-chat__message-attachment
|
|
1196
|
-
max-width:
|
|
1212
|
+
.str-chat__message .str-chat__message-attachment {
|
|
1213
|
+
--attachment-max-width: 235px;
|
|
1197
1214
|
}
|
|
1198
1215
|
}
|
|
1199
1216
|
|
|
@@ -4,31 +4,23 @@
|
|
|
4
4
|
/* The margin applied to every attachment in the attachment list */
|
|
5
5
|
--str-chat__attachment-margin: var(--str-chat__spacing-0_5);
|
|
6
6
|
|
|
7
|
-
/* The maximum allowed width and height of attachments, in case of gallery images this is the maximum size of the whole gallery (not just for a single image inside the gallery). In case of Angular, there are some [constraints](https://getstream.io/chat/docs/sdk/angular/components/AttachmentListComponent/#maximum-size) for the acceptable values you can provide for this variable. */
|
|
8
|
-
--str-chat__attachment-max-width: unset;
|
|
9
|
-
|
|
10
|
-
/* The height of scraped images, the default value is optimized for 1.91:1 aspect ratio */
|
|
11
|
-
--str-chat__scraped-image-height: unset;
|
|
12
|
-
|
|
13
|
-
/* The height of scraped videos, the default value is optimized for 16:9 aspect ratio */
|
|
14
|
-
--str-chat__scraped-video-height: unset;
|
|
15
|
-
|
|
16
7
|
/* The height of GIFs */
|
|
17
8
|
--str-chat__gif-height: calc(var(--str-chat__spacing-px) * 200);
|
|
18
|
-
|
|
19
|
-
/* The height of videos, the default value is the mase as `--str-chat__attachment-max-width`. In Angular SDK this is the maximum height, the video can be smaller based on the aspect ratio */
|
|
20
|
-
--str-chat__video-height: unset;
|
|
21
9
|
}
|
|
22
10
|
|
|
23
11
|
.str-chat__attachment-list {
|
|
12
|
+
/* The maximum allowed width and height of attachments, in case of gallery images this is the maximum size of the whole gallery (not just for a single image inside the gallery). There are some constraints for the acceptable values you can provide for this variable, [Angular documentation](https://getstream.io/chat/docs/sdk/angular/components/AttachmentListComponent/#maximum-size), [React documentation](https://getstream.io/chat/docs/sdk/react/message-components/attachment/#image-and-video-sizing). */
|
|
24
13
|
--str-chat__attachment-max-width: calc(
|
|
25
14
|
var(--str-chat__message-max-width) - calc(2 * var(--str-chat__attachment-margin))
|
|
26
15
|
);
|
|
27
16
|
|
|
17
|
+
/* The maximum height of videos, the default value is the mase as `--str-chat__attachment-max-width`. The rendered video can be smaller based on the aspect ratio */
|
|
28
18
|
--str-chat__video-height: var(--str-chat__attachment-max-width);
|
|
29
19
|
|
|
20
|
+
/* The height of scraped images, the default value is optimized for 1.91:1 aspect ratio */
|
|
30
21
|
--str-chat__scraped-image-height: calc(var(--str-chat__attachment-max-width) * calc(1 / 1.91));
|
|
31
22
|
|
|
23
|
+
/* The height of scraped videos, the default value is optimized for 16:9 aspect ratio */
|
|
32
24
|
--str-chat__scraped-video-height: calc(var(--str-chat__attachment-max-width) * calc(9 / 16));
|
|
33
25
|
|
|
34
26
|
display: flex;
|
|
@@ -104,12 +96,16 @@
|
|
|
104
96
|
// Images uploaded from files
|
|
105
97
|
.str-chat__message-attachment--image:not(.str-chat__message-attachment--card) {
|
|
106
98
|
img {
|
|
99
|
+
@include utils.clamped-height-from-original-image-dimensions(
|
|
100
|
+
'--str-chat__attachment-max-width',
|
|
101
|
+
'--str-chat__attachment-max-width'
|
|
102
|
+
);
|
|
103
|
+
|
|
107
104
|
// CDN resize requires max-width and height/max-height to be present on this element
|
|
108
105
|
max-width: var(--str-chat__attachment-max-width);
|
|
109
106
|
max-height: var(--str-chat__attachment-max-width);
|
|
110
107
|
object-fit: cover;
|
|
111
108
|
width: 100%;
|
|
112
|
-
height: 100%;
|
|
113
109
|
cursor: zoom-in;
|
|
114
110
|
}
|
|
115
111
|
}
|
|
@@ -117,20 +113,27 @@
|
|
|
117
113
|
// Video files: uploaded from files and scraped
|
|
118
114
|
.str-chat__message-attachment--video:not(.str-chat__message-attachment--card),
|
|
119
115
|
.str-chat__message-attachment-card--video .str-chat__message-attachment-card--header {
|
|
120
|
-
|
|
116
|
+
$maxWidth: var(--str-chat__attachment-max-width);
|
|
117
|
+
max-width: $maxWidth;
|
|
121
118
|
display: flex;
|
|
122
119
|
|
|
123
120
|
.str-chat__player-wrapper {
|
|
124
121
|
height: 100%;
|
|
125
122
|
width: 100%;
|
|
126
123
|
min-width: 0;
|
|
124
|
+
// CDN resize requires max-width to be present on this element - React
|
|
125
|
+
max-width: $maxWidth;
|
|
126
|
+
display: flex;
|
|
127
|
+
flex-direction: column;
|
|
127
128
|
|
|
128
129
|
.react-player,
|
|
129
130
|
.str-chat__video-angular {
|
|
130
131
|
height: 100%;
|
|
131
132
|
width: 100%;
|
|
132
|
-
// CDN resize requires max-width to be present on this element
|
|
133
|
-
max-width:
|
|
133
|
+
// CDN resize requires max-width to be present on this element - Angular
|
|
134
|
+
max-width: $maxWidth;
|
|
135
|
+
max-height: 100%;
|
|
136
|
+
min-height: 0;
|
|
134
137
|
}
|
|
135
138
|
}
|
|
136
139
|
}
|
|
@@ -140,11 +143,22 @@
|
|
|
140
143
|
}
|
|
141
144
|
|
|
142
145
|
.str-chat__message-attachment--video.str-chat__message-attachment-dynamic-size:not(.str-chat__message-attachment--card) {
|
|
143
|
-
|
|
146
|
+
$maxHeight: var(--str-chat__video-height);
|
|
147
|
+
|
|
148
|
+
max-height: $maxHeight;
|
|
149
|
+
|
|
150
|
+
.str-chat__player-wrapper {
|
|
151
|
+
@include utils.clamped-height-from-original-image-dimensions(
|
|
152
|
+
'--str-chat__video-height',
|
|
153
|
+
'--str-chat__attachment-max-width'
|
|
154
|
+
);
|
|
155
|
+
// CDN resize requires max-height to be present on this element - React
|
|
156
|
+
max-height: $maxHeight;
|
|
157
|
+
}
|
|
144
158
|
|
|
145
159
|
.str-chat__video-angular {
|
|
146
|
-
// CDN resize requires max-height to be present on this element
|
|
147
|
-
max-height:
|
|
160
|
+
// CDN resize requires max-height to be present on this element - Angular
|
|
161
|
+
max-height: $maxHeight;
|
|
148
162
|
}
|
|
149
163
|
}
|
|
150
164
|
|
|
@@ -39,3 +39,17 @@
|
|
|
39
39
|
display: none;
|
|
40
40
|
}
|
|
41
41
|
}
|
|
42
|
+
|
|
43
|
+
|
|
44
|
+
.str-chat__channel-list-react {
|
|
45
|
+
overflow: hidden;
|
|
46
|
+
|
|
47
|
+
.str-chat__channel-list-messenger-react {
|
|
48
|
+
overflow: hidden;
|
|
49
|
+
padding-bottom: var(--str-chat__spacing-2_5);
|
|
50
|
+
|
|
51
|
+
.str-chat__channel-list-messenger-react__main {
|
|
52
|
+
overflow-y: auto;
|
|
53
|
+
}
|
|
54
|
+
}
|
|
55
|
+
}
|
|
@@ -1,71 +1,88 @@
|
|
|
1
1
|
@use '../utils';
|
|
2
2
|
|
|
3
|
-
.str-chat__channel-search
|
|
4
|
-
|
|
5
|
-
padding: var(--str-chat__spacing-2_5);
|
|
3
|
+
.str-chat__channel-search {
|
|
4
|
+
position: relative;
|
|
6
5
|
|
|
7
|
-
.str-chat__channel-search-bar
|
|
8
|
-
@include utils.
|
|
9
|
-
width: calc(var(--str-chat__spacing-px) * 40);
|
|
10
|
-
height: calc(var(--str-chat__spacing-px) * 40);
|
|
6
|
+
.str-chat__channel-search-bar {
|
|
7
|
+
@include utils.flex-row-center;
|
|
11
8
|
padding: var(--str-chat__spacing-2_5);
|
|
12
|
-
cursor: pointer;
|
|
13
|
-
}
|
|
14
|
-
|
|
15
|
-
.str-chat__channel-search-input--wrapper {
|
|
16
|
-
display: flex;
|
|
17
|
-
align-items: center;
|
|
18
|
-
flex: 1;
|
|
19
|
-
padding: var(--str-chat__spacing-2_5);
|
|
20
|
-
min-width: 0;
|
|
21
9
|
|
|
22
|
-
.str-chat__channel-search-
|
|
23
|
-
.str-chat__channel-search-input--clear-button {
|
|
24
|
-
display: inline-flex;
|
|
25
|
-
padding: 0 var(--str-chat__spacing-2_5);
|
|
26
|
-
}
|
|
27
|
-
|
|
28
|
-
.str-chat__channel-search-input--clear-button {
|
|
10
|
+
.str-chat__channel-search-bar-button {
|
|
29
11
|
@include utils.button-reset;
|
|
12
|
+
width: calc(var(--str-chat__spacing-px) * 40);
|
|
13
|
+
height: calc(var(--str-chat__spacing-px) * 40);
|
|
14
|
+
padding: var(--str-chat__spacing-2_5);
|
|
30
15
|
cursor: pointer;
|
|
31
|
-
|
|
32
|
-
&:disabled {
|
|
33
|
-
cursor: default;
|
|
34
|
-
}
|
|
35
16
|
}
|
|
36
17
|
|
|
37
|
-
input {
|
|
18
|
+
.str-chat__channel-search-input--wrapper {
|
|
19
|
+
display: flex;
|
|
20
|
+
align-items: center;
|
|
38
21
|
flex: 1;
|
|
22
|
+
padding: var(--str-chat__spacing-2_5);
|
|
39
23
|
min-width: 0;
|
|
24
|
+
|
|
25
|
+
.str-chat__channel-search-input--icon,
|
|
26
|
+
.str-chat__channel-search-input--clear-button {
|
|
27
|
+
display: inline-flex;
|
|
28
|
+
padding: 0 var(--str-chat__spacing-2_5);
|
|
29
|
+
}
|
|
30
|
+
|
|
31
|
+
.str-chat__channel-search-input--clear-button {
|
|
32
|
+
@include utils.button-reset;
|
|
33
|
+
cursor: pointer;
|
|
34
|
+
|
|
35
|
+
&:disabled {
|
|
36
|
+
cursor: default;
|
|
37
|
+
}
|
|
38
|
+
}
|
|
39
|
+
|
|
40
|
+
input {
|
|
41
|
+
flex: 1;
|
|
42
|
+
min-width: 0;
|
|
43
|
+
}
|
|
40
44
|
}
|
|
41
45
|
}
|
|
42
|
-
}
|
|
43
46
|
|
|
44
|
-
.str-chat__channel-search-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
}
|
|
47
|
+
.str-chat__channel-search-container-searching {
|
|
48
|
+
width: 100%;
|
|
49
|
+
padding: var(--str-chat__spacing-5) var(--str-chat__spacing-4);
|
|
50
|
+
}
|
|
48
51
|
|
|
49
|
-
.str-chat__channel-search-
|
|
50
|
-
.str-chat__channel-search-container-empty {
|
|
51
|
-
display: flex;
|
|
52
|
-
flex-direction: column;
|
|
53
|
-
align-items: center;
|
|
52
|
+
.str-chat__channel-search-results-header {
|
|
54
53
|
width: 100%;
|
|
54
|
+
padding: var(--str-chat__spacing-5) var(--str-chat__spacing-4);
|
|
55
|
+
}
|
|
55
56
|
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
57
|
+
|
|
58
|
+
.str-chat__channel-search-result-list {
|
|
59
|
+
&.popup {
|
|
60
|
+
position: absolute;
|
|
61
|
+
left: 0;
|
|
62
|
+
right: 0;
|
|
60
63
|
}
|
|
61
|
-
}
|
|
62
64
|
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
65
|
+
.str-chat__channel-search-container-empty {
|
|
66
|
+
display: flex;
|
|
67
|
+
flex-direction: column;
|
|
68
|
+
align-items: center;
|
|
69
|
+
width: 100%;
|
|
70
|
+
padding: var(--str-chat__spacing-5) var(--str-chat__spacing-4);
|
|
71
|
+
|
|
72
|
+
svg {
|
|
73
|
+
height: calc(var(--str-chat__spacing-px) * 90 + var(--str-chat__spacing-20));
|
|
74
|
+
width: calc(var(--str-chat__spacing-px) * 90);
|
|
75
|
+
padding: var(--str-chat__spacing-10) 0;
|
|
76
|
+
}
|
|
77
|
+
}
|
|
78
|
+
|
|
79
|
+
.str-chat__channel-search-result {
|
|
80
|
+
@include utils.button-reset;
|
|
81
|
+
display: flex;
|
|
82
|
+
align-items: center;
|
|
83
|
+
width: 100%;
|
|
84
|
+
column-gap: var(--str-chat__spacing-2);
|
|
85
|
+
padding: var(--str-chat__spacing-3) var(--str-chat__spacing-2);
|
|
86
|
+
}
|
|
70
87
|
}
|
|
71
|
-
}
|
|
88
|
+
}
|
|
@@ -89,6 +89,25 @@
|
|
|
89
89
|
--str-chat__secondary-surface-color
|
|
90
90
|
);
|
|
91
91
|
|
|
92
|
+
--str-chat__channel-search-result-list-color: var(--str-chat__text-color);
|
|
93
|
+
|
|
94
|
+
--str-chat__channel-search-result-list-background-color: var(--str-chat__secondary-background-color);
|
|
95
|
+
|
|
96
|
+
/* Top border of the component */
|
|
97
|
+
--str-chat__channel-search-result-list-border-block-start: none;
|
|
98
|
+
|
|
99
|
+
/* Bottom border of the component */
|
|
100
|
+
--str-chat__channel-search-result-list-border-block-end: none;
|
|
101
|
+
|
|
102
|
+
/* Left (right in RTL layout) border of the component */
|
|
103
|
+
--str-chat__channel-search-result-list-border-inline-start: none;
|
|
104
|
+
|
|
105
|
+
/* Right (left in RTL layout) border of the component */
|
|
106
|
+
--str-chat__channel-search-result-list-border-inline-end: none;
|
|
107
|
+
|
|
108
|
+
/* Box shadow applied to the component */
|
|
109
|
+
--str-chat__channel-search-result-list-popup-box-shadow: 0 4px 4px var(--str-chat__box-shadow-color);
|
|
110
|
+
|
|
92
111
|
/* The font color used in the search results header */
|
|
93
112
|
--str-chat__channel-search-results-header-color: var(--str-chat__text-low-emphasis-color);
|
|
94
113
|
|
|
@@ -108,6 +127,25 @@
|
|
|
108
127
|
/* Right (left in RTL layout) border of the component */
|
|
109
128
|
--str-chat__channel-search-results-header-border-inline-end: none;
|
|
110
129
|
|
|
130
|
+
/* The font color used in the search results loading indicator */
|
|
131
|
+
--str-chat__channel-search-results-loading-indicator-color: var(--str-chat__text-low-emphasis-color);
|
|
132
|
+
|
|
133
|
+
/* The background color used in the search results loading indicator */
|
|
134
|
+
--str-chat__channel-search-results-loading-indicator-background-color: var(--str-chat__background-color);
|
|
135
|
+
|
|
136
|
+
/* Top border of the component */
|
|
137
|
+
--str-chat__channel-search-results-loading-indicator-border-block-start: none;
|
|
138
|
+
|
|
139
|
+
/* Bottom border of the component */
|
|
140
|
+
--str-chat__channel-search-results-loading-indicator-border-block-end: var(--str-chat__surface-color) 1px
|
|
141
|
+
solid;
|
|
142
|
+
|
|
143
|
+
/* Left (right in RTL layout) border of the component */
|
|
144
|
+
--str-chat__channel-search-results-loading-indicator-border-inline-start: none;
|
|
145
|
+
|
|
146
|
+
/* Right (left in RTL layout) border of the component */
|
|
147
|
+
--str-chat__channel-search-results-loading-indicator-border-inline-end: none;
|
|
148
|
+
|
|
111
149
|
/* The font color used in the empty search results indicator */
|
|
112
150
|
--str-chat__channel-search-results-empty-color: var(--str-chat__text-low-emphasis-color);
|
|
113
151
|
|
|
@@ -162,6 +200,16 @@
|
|
|
162
200
|
}
|
|
163
201
|
|
|
164
202
|
.str-chat__channel-search-result-list {
|
|
203
|
+
@include utils.component-layer-overrides('channel-search-result-list');
|
|
204
|
+
|
|
205
|
+
&.popup {
|
|
206
|
+
box-shadow: var(--str-chat__channel-search-result-list-popup-box-shadow);
|
|
207
|
+
}
|
|
208
|
+
|
|
209
|
+
.str-chat__channel-search-container-searching {
|
|
210
|
+
@include utils.component-layer-overrides('channel-search-results-loading-indicator');
|
|
211
|
+
}
|
|
212
|
+
|
|
165
213
|
.str-chat__channel-search-container-empty {
|
|
166
214
|
@include utils.component-layer-overrides('channel-search-results-empty');
|
|
167
215
|
font: var(--str-chat__subtitle2-medium-text);
|
|
@@ -71,6 +71,7 @@
|
|
|
71
71
|
grid-template-areas:
|
|
72
72
|
'avatar message'
|
|
73
73
|
'. replies'
|
|
74
|
+
'. translation-notice'
|
|
74
75
|
'. metadata';
|
|
75
76
|
column-gap: var(--str-chat__spacing-2);
|
|
76
77
|
grid-template-columns: auto 1fr;
|
|
@@ -81,6 +82,7 @@
|
|
|
81
82
|
grid-template-areas:
|
|
82
83
|
'message'
|
|
83
84
|
'replies'
|
|
85
|
+
'translation-notice'
|
|
84
86
|
'metadata';
|
|
85
87
|
justify-items: end;
|
|
86
88
|
|
|
@@ -166,6 +168,16 @@
|
|
|
166
168
|
}
|
|
167
169
|
}
|
|
168
170
|
|
|
171
|
+
.str-chat__translation-notice {
|
|
172
|
+
grid-area: translation-notice;
|
|
173
|
+
|
|
174
|
+
button {
|
|
175
|
+
cursor: pointer;
|
|
176
|
+
padding: var(--str-chat__spacing-1) 0;
|
|
177
|
+
margin: 0;
|
|
178
|
+
}
|
|
179
|
+
}
|
|
180
|
+
|
|
169
181
|
.str-chat__message-metadata {
|
|
170
182
|
grid-area: metadata;
|
|
171
183
|
display: flex;
|