stream-chat-angular 5.9.0 → 5.10.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/assets/version.d.ts +1 -1
- package/esm2020/assets/version.mjs +2 -2
- package/esm2020/lib/attachment.service.mjs +3 -3
- package/esm2020/lib/avatar-placeholder/avatar-placeholder.component.mjs +2 -2
- package/esm2020/lib/channel/channel.component.mjs +2 -2
- package/esm2020/lib/channel.service.mjs +4 -4
- package/esm2020/lib/chat-client.service.mjs +2 -2
- package/esm2020/lib/custom-templates.service.mjs +44 -44
- package/esm2020/lib/icon/icon-placeholder/icon-placeholder.component.mjs +2 -2
- package/esm2020/lib/icon/loading-indicator-placeholder/loading-indicator-placeholder.component.mjs +2 -2
- package/esm2020/lib/message/message.component.mjs +3 -3
- package/esm2020/lib/message-actions-box/message-actions-box.component.mjs +3 -3
- package/esm2020/lib/message-actions.service.mjs +2 -2
- package/esm2020/lib/message-bounce-prompt/message-bounce-prompt.component.mjs +2 -2
- package/esm2020/lib/message-input/autocomplete-textarea/autocomplete-textarea.component.mjs +88 -33
- package/esm2020/lib/message-input/emoji-input.service.mjs +3 -3
- package/esm2020/lib/message-input/message-input-config.service.mjs +10 -3
- package/esm2020/lib/message-input/message-input.component.mjs +2 -2
- package/esm2020/lib/message-input/textarea/textarea.component.mjs +2 -2
- package/esm2020/lib/message-reactions/message-reactions.component.mjs +3 -3
- package/esm2020/lib/message-reactions-selector/message-reactions-selector.component.mjs +3 -3
- package/esm2020/lib/message-reactions.service.mjs +2 -2
- package/esm2020/lib/notification/notification.component.mjs +2 -2
- package/esm2020/lib/notification.service.mjs +2 -2
- package/esm2020/lib/stream-i18n.service.mjs +2 -2
- package/esm2020/lib/theme.service.mjs +2 -2
- package/esm2020/lib/thread/thread.component.mjs +2 -2
- package/esm2020/lib/types.mjs +1 -1
- package/fesm2015/stream-chat-angular.mjs +166 -107
- package/fesm2015/stream-chat-angular.mjs.map +1 -1
- package/fesm2020/stream-chat-angular.mjs +164 -104
- package/fesm2020/stream-chat-angular.mjs.map +1 -1
- package/lib/attachment.service.d.ts +3 -3
- package/lib/avatar-placeholder/avatar-placeholder.component.d.ts +1 -1
- package/lib/channel/channel.component.d.ts +1 -1
- package/lib/channel.service.d.ts +15 -15
- package/lib/chat-client.service.d.ts +3 -3
- package/lib/custom-templates.service.d.ts +43 -43
- package/lib/icon/icon-placeholder/icon-placeholder.component.d.ts +1 -1
- package/lib/icon/loading-indicator-placeholder/loading-indicator-placeholder.component.d.ts +1 -1
- package/lib/message/message.component.d.ts +2 -2
- package/lib/message-actions-box/message-actions-box.component.d.ts +2 -2
- package/lib/message-actions.service.d.ts +2 -2
- package/lib/message-bounce-prompt/message-bounce-prompt.component.d.ts +1 -1
- package/lib/message-input/autocomplete-textarea/autocomplete-textarea.component.d.ts +8 -5
- package/lib/message-input/emoji-input.service.d.ts +2 -2
- package/lib/message-input/message-input-config.service.d.ts +11 -3
- package/lib/message-input/message-input.component.d.ts +6 -6
- package/lib/message-input/textarea/textarea.component.d.ts +2 -2
- package/lib/message-reactions/message-reactions.component.d.ts +2 -2
- package/lib/message-reactions-selector/message-reactions-selector.component.d.ts +2 -2
- package/lib/message-reactions.service.d.ts +2 -2
- package/lib/notification/notification.component.d.ts +1 -1
- package/lib/notification.service.d.ts +1 -1
- package/lib/stream-i18n.service.d.ts +1 -1
- package/lib/theme.service.d.ts +1 -1
- package/lib/thread/thread.component.d.ts +1 -1
- package/lib/types.d.ts +39 -0
- package/package.json +1 -1
- package/src/assets/version.ts +1 -1
|
@@ -18,13 +18,13 @@ import { NgxFloatUiModule } from 'ngx-float-ui';
|
|
|
18
18
|
import prettybytes from 'pretty-bytes';
|
|
19
19
|
import fixWebmDuration from 'fix-webm-duration';
|
|
20
20
|
import transliterate from '@stream-io/transliterate';
|
|
21
|
-
import * as
|
|
21
|
+
import * as i8 from 'angular-mentions';
|
|
22
22
|
import { MentionModule } from 'angular-mentions';
|
|
23
23
|
|
|
24
|
-
const version = '5.
|
|
24
|
+
const version = '5.10.0';
|
|
25
25
|
|
|
26
26
|
/**
|
|
27
|
-
* The `NotificationService` can be used to add or remove notifications. By default the [`NotificationList`](
|
|
27
|
+
* The `NotificationService` can be used to add or remove notifications. By default the [`NotificationList`](/chat/docs/sdk/angular/components/NotificationListComponent/) component displays the currently active notifications.
|
|
28
28
|
*/
|
|
29
29
|
class NotificationService {
|
|
30
30
|
constructor() {
|
|
@@ -200,7 +200,7 @@ class ChatClientService {
|
|
|
200
200
|
});
|
|
201
201
|
}
|
|
202
202
|
/**
|
|
203
|
-
* Disconnects the current user, and closes the WebSocket connection. Useful when disconnecting a chat user, use in combination with [`reset`](
|
|
203
|
+
* Disconnects the current user, and closes the WebSocket connection. Useful when disconnecting a chat user, use in combination with [`reset`](/chat/docs/sdk/angular/services/ChannelService/#reset/).
|
|
204
204
|
*/
|
|
205
205
|
disconnectUser() {
|
|
206
206
|
return __awaiter(this, void 0, void 0, function* () {
|
|
@@ -766,7 +766,7 @@ class ChannelService {
|
|
|
766
766
|
return this._init(options);
|
|
767
767
|
}
|
|
768
768
|
/**
|
|
769
|
-
* Resets the `activeChannel$`, `channels$` and `activeChannelMessages$` Observables. Useful when disconnecting a chat user, use in combination with [`disconnectUser`](
|
|
769
|
+
* Resets the `activeChannel$`, `channels$` and `activeChannelMessages$` Observables. Useful when disconnecting a chat user, use in combination with [`disconnectUser`](/chat/docs/sdk/angular/services/ChatClientService/#disconnectuser/).
|
|
770
770
|
*/
|
|
771
771
|
reset() {
|
|
772
772
|
var _a, _b;
|
|
@@ -915,7 +915,7 @@ class ChannelService {
|
|
|
915
915
|
}
|
|
916
916
|
/**
|
|
917
917
|
* Uploads files to the channel. If you want to know more about [file uploads](https://getstream.io/chat/docs/javascript/file_uploads/?language=javascript) check out the platform documentation.
|
|
918
|
-
* @param uploads the attachments to upload (output of the [`AttachmentService`](
|
|
918
|
+
* @param uploads the attachments to upload (output of the [`AttachmentService`](/chat/docs/sdk/angular/services/AttachmentService/))
|
|
919
919
|
* @returns the result of file upload requests
|
|
920
920
|
*/
|
|
921
921
|
uploadAttachments(uploads) {
|
|
@@ -986,7 +986,7 @@ class ChannelService {
|
|
|
986
986
|
}
|
|
987
987
|
/**
|
|
988
988
|
* Deletes an uploaded file by URL. If you want to know more about [file uploads](https://getstream.io/chat/docs/javascript/file_uploads/?language=javascript) check out the platform documentation
|
|
989
|
-
* @param attachmentUpload Attachment to be deleted (output of the [`AttachmentService`](
|
|
989
|
+
* @param attachmentUpload Attachment to be deleted (output of the [`AttachmentService`](/chat/docs/sdk/angular/services/AttachmentService/))
|
|
990
990
|
*/
|
|
991
991
|
deleteAttachment(attachmentUpload) {
|
|
992
992
|
return __awaiter(this, void 0, void 0, function* () {
|
|
@@ -1981,7 +1981,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.0.4", ngImpor
|
|
|
1981
1981
|
}], ctorParameters: function () { return [{ type: ChatClientService }, { type: i0.NgZone }, { type: NotificationService }]; } });
|
|
1982
1982
|
|
|
1983
1983
|
/**
|
|
1984
|
-
* The `ThemeService` can be used to change the theme of the chat UI and to customize the theme. Our [theming guide](
|
|
1984
|
+
* The `ThemeService` can be used to change the theme of the chat UI and to customize the theme. Our [theming guide](/chat/docs/sdk/angular/theming/themingv2/) gives a complete overview about the topic.
|
|
1985
1985
|
*/
|
|
1986
1986
|
class ThemeService {
|
|
1987
1987
|
constructor() {
|
|
@@ -2105,7 +2105,7 @@ class AttachmentService {
|
|
|
2105
2105
|
/**
|
|
2106
2106
|
* You can get and set the list if uploaded custom attachments
|
|
2107
2107
|
*
|
|
2108
|
-
* By default the SDK components won't display these, but you can provide your own `customAttachmentPreviewListTemplate$` and `customAttachmentListTemplate$` for the [`CustomTemplatesService`](
|
|
2108
|
+
* By default the SDK components won't display these, but you can provide your own `customAttachmentPreviewListTemplate$` and `customAttachmentListTemplate$` for the [`CustomTemplatesService`](/chat/docs/sdk/angular/services/CustomTemplatesService/).
|
|
2109
2109
|
*/
|
|
2110
2110
|
this.customAttachments$ = new BehaviorSubject([]);
|
|
2111
2111
|
/**
|
|
@@ -2241,7 +2241,7 @@ class AttachmentService {
|
|
|
2241
2241
|
/**
|
|
2242
2242
|
* You can add custom `image`, `video` and `file` attachments using this method.
|
|
2243
2243
|
*
|
|
2244
|
-
* Note: If you just want to use your own CDN for file uploads, you don't necessary need this method, you can just specify you own upload function in the [`ChannelService`](
|
|
2244
|
+
* Note: If you just want to use your own CDN for file uploads, you don't necessary need this method, you can just specify you own upload function in the [`ChannelService`](/chat/docs/sdk/angular/services/ChannelService/)
|
|
2245
2245
|
* @param attachment
|
|
2246
2246
|
*/
|
|
2247
2247
|
addAttachment(attachment) {
|
|
@@ -2874,7 +2874,7 @@ const en = {
|
|
|
2874
2874
|
};
|
|
2875
2875
|
|
|
2876
2876
|
/**
|
|
2877
|
-
* The `StreamI18nService` can be used to customize the labels of the chat UI. Our [translation guide](
|
|
2877
|
+
* The `StreamI18nService` can be used to customize the labels of the chat UI. Our [translation guide](/chat/docs/sdk/angular/concepts/translation/) covers this topic in detail.
|
|
2878
2878
|
*/
|
|
2879
2879
|
class StreamI18nService {
|
|
2880
2880
|
constructor(translteService) {
|
|
@@ -3071,183 +3071,183 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.0.4", ngImpor
|
|
|
3071
3071
|
class CustomTemplatesService {
|
|
3072
3072
|
constructor() {
|
|
3073
3073
|
/**
|
|
3074
|
-
* The autocomplete list item template for mentioning users (used in the [`AutocompleteTextareaComponent`](
|
|
3074
|
+
* The autocomplete list item template for mentioning users (used in the [`AutocompleteTextareaComponent`](/chat/docs/sdk/angular/components/AutocompleteTextareaComponent/))
|
|
3075
3075
|
*/
|
|
3076
3076
|
this.mentionAutocompleteItemTemplate$ = new BehaviorSubject(undefined);
|
|
3077
3077
|
/**
|
|
3078
|
-
* The autocomplete list item template for commands (used in the [`AutocompleteTextareaComponent`](
|
|
3078
|
+
* The autocomplete list item template for commands (used in the [`AutocompleteTextareaComponent`](/chat/docs/sdk/angular/components/AutocompleteTextareaComponent/))
|
|
3079
3079
|
*/
|
|
3080
3080
|
this.commandAutocompleteItemTemplate$ = new BehaviorSubject(undefined);
|
|
3081
3081
|
/**
|
|
3082
|
-
* Template used to display an item in the [channel list](
|
|
3082
|
+
* Template used to display an item in the [channel list](/chat/docs/sdk/angular/components/ChannelListComponent/) (instead of the default [channal list item](/chat/docs/sdk/angular/components/ChannelPreviewComponent/))
|
|
3083
3083
|
*
|
|
3084
3084
|
*/
|
|
3085
3085
|
this.channelPreviewTemplate$ = new BehaviorSubject(undefined);
|
|
3086
3086
|
/**
|
|
3087
|
-
* The template used for displaying a [mention inside a message](
|
|
3087
|
+
* The template used for displaying a [mention inside a message](/chat/docs/sdk/angular/code-examples/mention-actions/)
|
|
3088
3088
|
*
|
|
3089
3089
|
*/
|
|
3090
3090
|
this.mentionTemplate$ = new BehaviorSubject(undefined);
|
|
3091
3091
|
/**
|
|
3092
|
-
* The template for [emoji picker](
|
|
3092
|
+
* The template for [emoji picker](/chat/docs/sdk/angular/code-examples/emoji-picker)
|
|
3093
3093
|
*
|
|
3094
3094
|
*/
|
|
3095
3095
|
this.emojiPickerTemplate$ = new BehaviorSubject(undefined);
|
|
3096
3096
|
/**
|
|
3097
|
-
* The typing indicator template used in the [message list](
|
|
3097
|
+
* The typing indicator template used in the [message list](/chat/docs/sdk/angular/components/MessageListComponent/)
|
|
3098
3098
|
*
|
|
3099
3099
|
*/
|
|
3100
3100
|
this.typingIndicatorTemplate$ = new BehaviorSubject(undefined);
|
|
3101
3101
|
/**
|
|
3102
|
-
* The template used to display a message in the [message list](
|
|
3102
|
+
* The template used to display a message in the [message list](/chat/docs/sdk/angular/components/MessageListComponent/) (instead of the [default message component](/chat/docs/sdk/angular/components/MessageComponent/))
|
|
3103
3103
|
*
|
|
3104
3104
|
*/
|
|
3105
3105
|
this.messageTemplate$ = new BehaviorSubject(undefined);
|
|
3106
3106
|
/**
|
|
3107
|
-
* The template for channel actions displayed in the [channel header](
|
|
3107
|
+
* The template for channel actions displayed in the [channel header](/chat/docs/sdk/angular/components/ChannelHeaderComponent/) (by default no channel action is displayed)
|
|
3108
3108
|
*
|
|
3109
3109
|
*/
|
|
3110
3110
|
this.channelActionsTemplate$ = new BehaviorSubject(undefined);
|
|
3111
3111
|
/**
|
|
3112
|
-
* The template used to display attachments of a [message](
|
|
3112
|
+
* The template used to display attachments of a [message](/chat/docs/sdk/angular/components/MessageComponent/) (instead of the [default attachment list](/chat/docs/sdk/angular/components/AttachmentListComponent/))
|
|
3113
3113
|
*
|
|
3114
3114
|
*/
|
|
3115
3115
|
this.attachmentListTemplate$ = new BehaviorSubject(undefined);
|
|
3116
3116
|
/**
|
|
3117
|
-
* The template used to display attachments in the [message input](
|
|
3117
|
+
* The template used to display attachments in the [message input](/chat/docs/sdk/angular/components/MessageInputComponent) component (instead of the [default attachment preview](/chat/docs/sdk/angular/components/AttachmentPreviewListComponent))
|
|
3118
3118
|
*
|
|
3119
3119
|
*/
|
|
3120
3120
|
this.attachmentPreviewListTemplate$ = new BehaviorSubject(undefined);
|
|
3121
3121
|
/**
|
|
3122
|
-
* The template used to display avatars for channels and users (instead of the [default avatar](
|
|
3122
|
+
* The template used to display avatars for channels and users (instead of the [default avatar](/chat/docs/sdk/angular/components/AvatarComponent/))
|
|
3123
3123
|
*
|
|
3124
3124
|
*/
|
|
3125
3125
|
this.avatarTemplate$ = new BehaviorSubject(undefined);
|
|
3126
3126
|
/**
|
|
3127
|
-
* Template for displaying icons (instead of the [default icon component](
|
|
3127
|
+
* Template for displaying icons (instead of the [default icon component](/chat/docs/sdk/angular/components/IconComponent/))
|
|
3128
3128
|
*
|
|
3129
3129
|
*/
|
|
3130
3130
|
this.iconTemplate$ = new BehaviorSubject(undefined);
|
|
3131
3131
|
/**
|
|
3132
|
-
* Template for displaying the loading indicator (instead of the [default loading indicator](
|
|
3132
|
+
* Template for displaying the loading indicator (instead of the [default loading indicator](/chat/docs/sdk/angular/components/LoadingIndicatorComponent/))
|
|
3133
3133
|
*
|
|
3134
3134
|
*/
|
|
3135
3135
|
this.loadingIndicatorTemplate$ = new BehaviorSubject(undefined);
|
|
3136
3136
|
/**
|
|
3137
|
-
* Template for displaying the message actions box (instead of the [default message actions box](
|
|
3137
|
+
* Template for displaying the message actions box (instead of the [default message actions box](/chat/docs/sdk/angular/components/MessageActionsBoxComponent/))
|
|
3138
3138
|
*
|
|
3139
3139
|
*/
|
|
3140
3140
|
this.messageActionsBoxTemplate$ = new BehaviorSubject(undefined);
|
|
3141
3141
|
/**
|
|
3142
|
-
* The template used for displaying an item in the [message actions box](
|
|
3142
|
+
* The template used for displaying an item in the [message actions box](/chat/docs/sdk/angular/components/MessageActionsBoxComponent/)
|
|
3143
3143
|
*
|
|
3144
3144
|
*/
|
|
3145
3145
|
this.messageActionsBoxItemTemplate$ = new BehaviorSubject(undefined);
|
|
3146
3146
|
/**
|
|
3147
|
-
* The template used to display the reactions of a [message](
|
|
3147
|
+
* The template used to display the reactions of a [message](/chat/docs/sdk/angular/components/MessageComponent/), and the selector to add a reaction to a message (instead of the [default message reactions component](/chat/docs/sdk/angular/components/MessageReactionsComponent/))
|
|
3148
3148
|
*
|
|
3149
3149
|
*/
|
|
3150
3150
|
this.messageReactionsTemplate$ = new BehaviorSubject(undefined);
|
|
3151
3151
|
/**
|
|
3152
|
-
* The template used to display the reactions of a [message](
|
|
3152
|
+
* The template used to display the reactions of a [message](/chat/docs/sdk/angular/components/MessageComponent/), and the selector to add a reaction to a message (instead of the [default message reactions component](/chat/docs/sdk/angular/components/MessageReactionsComponent/))
|
|
3153
3153
|
*
|
|
3154
3154
|
*/
|
|
3155
3155
|
this.messageReactionsSelectorTemplate$ = new BehaviorSubject(undefined);
|
|
3156
3156
|
/**
|
|
3157
|
-
* The template used to display a modal window (instead of the [default modal](
|
|
3157
|
+
* The template used to display a modal window (instead of the [default modal](/chat/docs/sdk/angular/components/ModalComponent/))
|
|
3158
3158
|
*
|
|
3159
3159
|
*/
|
|
3160
3160
|
this.modalTemplate$ = new BehaviorSubject(undefined);
|
|
3161
3161
|
/**
|
|
3162
|
-
* The template used to override the [default notification component](
|
|
3162
|
+
* The template used to override the [default notification component](/chat/docs/sdk/angular/components/NotificationComponent/)
|
|
3163
3163
|
*
|
|
3164
3164
|
*/
|
|
3165
3165
|
this.notificationTemplate$ = new BehaviorSubject(undefined);
|
|
3166
3166
|
/**
|
|
3167
|
-
* The template used for header of a [thread](
|
|
3167
|
+
* The template used for header of a [thread](/chat/docs/sdk/angular/components/ThreadComponent/)
|
|
3168
3168
|
*
|
|
3169
3169
|
*/
|
|
3170
3170
|
this.threadHeaderTemplate$ = new BehaviorSubject(undefined);
|
|
3171
3171
|
/**
|
|
3172
|
-
* The template used for displaying the delivered state of the message inside the [message component](
|
|
3172
|
+
* The template used for displaying the delivered state of the message inside the [message component](/chat/docs/sdk/angular/components/MessageComponent/)
|
|
3173
3173
|
*
|
|
3174
3174
|
* Displayed for the last message sent by the current user, if the message isn't yet read by anyone
|
|
3175
3175
|
*
|
|
3176
3176
|
*/
|
|
3177
3177
|
this.deliveredStatusTemplate$ = new BehaviorSubject(undefined);
|
|
3178
3178
|
/**
|
|
3179
|
-
* The template used for displaying the sending state of the message inside the [message component](
|
|
3179
|
+
* The template used for displaying the sending state of the message inside the [message component](/chat/docs/sdk/angular/components/MessageComponent/)
|
|
3180
3180
|
*
|
|
3181
3181
|
* Displayed for the last message sent by the current user, if the message is currently being sent
|
|
3182
3182
|
*
|
|
3183
3183
|
*/
|
|
3184
3184
|
this.sendingStatusTemplate$ = new BehaviorSubject(undefined);
|
|
3185
3185
|
/**
|
|
3186
|
-
* The template used for displaying the sent state of the message inside the [message component](
|
|
3186
|
+
* The template used for displaying the sent state of the message inside the [message component](/chat/docs/sdk/angular/components/MessageComponent/)
|
|
3187
3187
|
*
|
|
3188
3188
|
* Displayed for the last message sent by the current user, if the message is read at least by one user
|
|
3189
3189
|
*
|
|
3190
3190
|
*/
|
|
3191
3191
|
this.readStatusTemplate$ = new BehaviorSubject(undefined);
|
|
3192
3192
|
/**
|
|
3193
|
-
* Template to display custom metadata inside [message component](
|
|
3193
|
+
* Template to display custom metadata inside [message component](/chat/docs/sdk/angular/components/MessageComponent/)
|
|
3194
3194
|
*
|
|
3195
3195
|
*/
|
|
3196
3196
|
this.customMessageMetadataTemplate$ = new BehaviorSubject(undefined);
|
|
3197
3197
|
/**
|
|
3198
|
-
* The template used to display additional information about a channel under the channel name inside the [channel header component](
|
|
3198
|
+
* The template used to display additional information about a channel under the channel name inside the [channel header component](/chat/docs/sdk/angular/components/ChannelHeaderComponent/)
|
|
3199
3199
|
*
|
|
3200
3200
|
*/
|
|
3201
3201
|
this.channelHeaderInfoTemplate$ = new BehaviorSubject(undefined);
|
|
3202
3202
|
/**
|
|
3203
|
-
* The template used for displaying file upload/attachment selector inside the [message input](
|
|
3203
|
+
* The template used for displaying file upload/attachment selector inside the [message input](/chat/docs/sdk/angular/components/MessageInputComponent/)
|
|
3204
3204
|
*
|
|
3205
3205
|
*/
|
|
3206
3206
|
this.customAttachmentUploadTemplate$ = new BehaviorSubject(undefined);
|
|
3207
3207
|
/**
|
|
3208
|
-
* The template that can be used to override how a single image attachment is displayed inside the [attachment list](
|
|
3208
|
+
* The template that can be used to override how a single image attachment is displayed inside the [attachment list](/chat/docs/sdk/angular/components/AttachmentListComponent/)
|
|
3209
3209
|
*/
|
|
3210
3210
|
this.imageAttachmentTemplate$ = new BehaviorSubject(undefined);
|
|
3211
3211
|
/**
|
|
3212
|
-
* The template that can be used to override how a voice recording attachment is displayed inside the [attachment list](
|
|
3212
|
+
* The template that can be used to override how a voice recording attachment is displayed inside the [attachment list](/chat/docs/sdk/angular/components/AttachmentListComponent/), by default the [voice recording component](/chat/docs/sdk/angular/components/VoiceRecordingComponent/) is used
|
|
3213
3213
|
*/
|
|
3214
3214
|
this.voiceRecordingAttachmentTemplate$ = new BehaviorSubject(undefined);
|
|
3215
3215
|
/**
|
|
3216
|
-
* The template that can be used to override how a video attachment is displayed inside the [attachment list](
|
|
3216
|
+
* The template that can be used to override how a video attachment is displayed inside the [attachment list](/chat/docs/sdk/angular/components/AttachmentListComponent/)
|
|
3217
3217
|
*/
|
|
3218
3218
|
this.videoAttachmentTemplate$ = new BehaviorSubject(undefined);
|
|
3219
3219
|
/**
|
|
3220
|
-
* The template that can be used to override how image gallery is displayed inside the [attachment list](
|
|
3220
|
+
* The template that can be used to override how image gallery is displayed inside the [attachment list](/chat/docs/sdk/angular/components/AttachmentListComponent/)
|
|
3221
3221
|
*/
|
|
3222
3222
|
this.galleryAttachmentTemplate$ = new BehaviorSubject(undefined);
|
|
3223
3223
|
/**
|
|
3224
|
-
* The template that can be used to override how a file attachment is displayed inside the [attachment list](
|
|
3224
|
+
* The template that can be used to override how a file attachment is displayed inside the [attachment list](/chat/docs/sdk/angular/components/AttachmentListComponent/)
|
|
3225
3225
|
*/
|
|
3226
3226
|
this.fileAttachmentTemplate$ = new BehaviorSubject(undefined);
|
|
3227
3227
|
/**
|
|
3228
|
-
* The template that can be used to override how a card attachment is displayed inside the [attachment list](
|
|
3228
|
+
* The template that can be used to override how a card attachment is displayed inside the [attachment list](/chat/docs/sdk/angular/components/AttachmentListComponent/)
|
|
3229
3229
|
*/
|
|
3230
3230
|
this.cardAttachmentTemplate$ = new BehaviorSubject(undefined);
|
|
3231
3231
|
/**
|
|
3232
|
-
* The template that can be used to override how attachment actions are displayed inside the [attachment list](
|
|
3232
|
+
* The template that can be used to override how attachment actions are displayed inside the [attachment list](/chat/docs/sdk/angular/components/AttachmentListComponent/)
|
|
3233
3233
|
*/
|
|
3234
3234
|
this.attachmentActionsTemplate$ = new BehaviorSubject(undefined);
|
|
3235
3235
|
/**
|
|
3236
|
-
* The template used to display [system messages](https://getstream.io/chat/docs/javascript/silent_messages/?language=javascript&q=system) indise the [message component](
|
|
3236
|
+
* The template used to display [system messages](https://getstream.io/chat/docs/javascript/silent_messages/?language=javascript&q=system) indise the [message component](/chat/docs/sdk/angular/components/MessageComponent/)
|
|
3237
3237
|
*/
|
|
3238
3238
|
this.systemMessageTemplate$ = new BehaviorSubject(undefined);
|
|
3239
3239
|
/**
|
|
3240
|
-
* The template used to display the date separator inside the [message list](
|
|
3240
|
+
* The template used to display the date separator inside the [message list](/chat/docs/sdk/angular/components/MessageListComponent/)
|
|
3241
3241
|
*/
|
|
3242
3242
|
this.dateSeparatorTemplate$ = new BehaviorSubject(undefined);
|
|
3243
3243
|
/**
|
|
3244
|
-
* The template used to display unread messages indicator inside the [message list](
|
|
3244
|
+
* The template used to display unread messages indicator inside the [message list](/chat/docs/sdk/angular/components/MessageListComponent/) when the channel is opened
|
|
3245
3245
|
*
|
|
3246
3246
|
* This UI element is used to separate unread messages from read messages
|
|
3247
3247
|
*/
|
|
3248
3248
|
this.newMessagesIndicatorTemplate$ = new BehaviorSubject(undefined);
|
|
3249
3249
|
/**
|
|
3250
|
-
* The template used to display unread messages notification inside the [message list](
|
|
3250
|
+
* The template used to display unread messages notification inside the [message list](/chat/docs/sdk/angular/components/MessageListComponent/) when the channel is opened
|
|
3251
3251
|
*
|
|
3252
3252
|
* Users can use this notification to jump to the first unread message when it's clicked
|
|
3253
3253
|
*/
|
|
@@ -3261,28 +3261,28 @@ class CustomTemplatesService {
|
|
|
3261
3261
|
*/
|
|
3262
3262
|
this.emptyThreadMessageListPlaceholder$ = new BehaviorSubject(undefined);
|
|
3263
3263
|
/**
|
|
3264
|
-
* The template used to display the [message bounce prompt](
|
|
3264
|
+
* The template used to display the [message bounce prompt](/chat/docs/sdk/angular/components/MessageBouncePromptComponent/)
|
|
3265
3265
|
*/
|
|
3266
3266
|
this.messageBouncePromptTemplate$ = new BehaviorSubject(undefined);
|
|
3267
3267
|
/**
|
|
3268
|
-
* Template used to display the channel information inside the [channel list item](
|
|
3268
|
+
* Template used to display the channel information inside the [channel list item](/chat/docs/sdk/angular/components/ChannelPreviewComponent/)
|
|
3269
3269
|
*
|
|
3270
3270
|
*/
|
|
3271
3271
|
this.channelPreviewInfoTemplate$ = new BehaviorSubject(undefined);
|
|
3272
3272
|
/**
|
|
3273
|
-
* The template used to display custom attachment previews in the [message input component](
|
|
3273
|
+
* The template used to display custom attachment previews in the [message input component](/chat/docs/sdk/angular/components/MessageInputComponent/)
|
|
3274
3274
|
*/
|
|
3275
3275
|
this.customAttachmentPreviewListTemplate$ = new BehaviorSubject(undefined);
|
|
3276
3276
|
/**
|
|
3277
|
-
* The template used to display custom attachments in the [message component](
|
|
3277
|
+
* The template used to display custom attachments in the [message component](/chat/docs/sdk/angular/components/MessageComponent/)
|
|
3278
3278
|
*/
|
|
3279
3279
|
this.customAttachmentListTemplate$ = new BehaviorSubject(undefined);
|
|
3280
3280
|
/**
|
|
3281
|
-
* The template used to display the number of thread replies inside the [message component](
|
|
3281
|
+
* The template used to display the number of thread replies inside the [message component](/chat/docs/sdk/angular/components/MessageComponent/)
|
|
3282
3282
|
*/
|
|
3283
3283
|
this.threadLinkButton$ = new BehaviorSubject(undefined);
|
|
3284
3284
|
/**
|
|
3285
|
-
* Template to display custom metadata inside the message bubble of the [message component](
|
|
3285
|
+
* Template to display custom metadata inside the message bubble of the [message component](/chat/docs/sdk/angular/components/MessageComponent/)
|
|
3286
3286
|
*
|
|
3287
3287
|
* To properly position your template you should override the `grid-template-areas` of the `.str-chat__message-inner` selector
|
|
3288
3288
|
*/
|
|
@@ -3299,7 +3299,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.0.4", ngImpor
|
|
|
3299
3299
|
}], ctorParameters: function () { return []; } });
|
|
3300
3300
|
|
|
3301
3301
|
/**
|
|
3302
|
-
* The `AvatarPlaceholder` component displays the [default avatar](
|
|
3302
|
+
* The `AvatarPlaceholder` component displays the [default avatar](/chat/docs/sdk/angular/components/AvatarComponent/) unless a [custom template](/chat/docs/sdk/angular/services/CustomTemplatesService/) is provided. This component is used by the SDK internally, you likely won't need to use it.
|
|
3303
3303
|
*/
|
|
3304
3304
|
class AvatarPlaceholderComponent {
|
|
3305
3305
|
constructor(customTemplatesService) {
|
|
@@ -3375,7 +3375,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.0.4", ngImpor
|
|
|
3375
3375
|
}] } });
|
|
3376
3376
|
|
|
3377
3377
|
/**
|
|
3378
|
-
* The `IconPlaceholder` component displays the [default icons](
|
|
3378
|
+
* The `IconPlaceholder` component displays the [default icons](/chat/docs/sdk/angular/components/IconComponent/) unless a [custom template](/chat/docs/sdk/angular/services/CustomTemplatesService/) is provided. This component is used by the SDK internally, you likely won't need to use it.
|
|
3379
3379
|
*/
|
|
3380
3380
|
class IconPlaceholderComponent {
|
|
3381
3381
|
constructor(customTemplatesService) {
|
|
@@ -3411,7 +3411,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.0.4", ngImpor
|
|
|
3411
3411
|
}], ctorParameters: function () { return []; } });
|
|
3412
3412
|
|
|
3413
3413
|
/**
|
|
3414
|
-
* The `LoadingInficatorPlaceholder` component displays the [default loading indicator](
|
|
3414
|
+
* The `LoadingInficatorPlaceholder` component displays the [default loading indicator](/chat/docs/sdk/angular/components/LoadingIndicatorComponent/) unless a [custom template](/chat/docs/sdk/angular/services/CustomTemplatesService/) is provided. This component is used by the SDK internally, you likely won't need to use it.
|
|
3415
3415
|
*/
|
|
3416
3416
|
class LoadingIndicatorPlaceholderComponent {
|
|
3417
3417
|
constructor(customTemplatesService) {
|
|
@@ -3426,7 +3426,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.0.4", ngImpor
|
|
|
3426
3426
|
}], ctorParameters: function () { return [{ type: CustomTemplatesService }]; } });
|
|
3427
3427
|
|
|
3428
3428
|
/**
|
|
3429
|
-
* The message actions service provides customization options for the [message actions](
|
|
3429
|
+
* The message actions service provides customization options for the [message actions](/chat/docs/sdk/angular/components/MessageActionsBoxComponent)
|
|
3430
3430
|
*/
|
|
3431
3431
|
class MessageActionsService {
|
|
3432
3432
|
constructor(chatClientService, notificationService, channelService) {
|
|
@@ -3616,7 +3616,7 @@ class MessageReactionsService {
|
|
|
3616
3616
|
/**
|
|
3617
3617
|
* The enabled [reactions](https://getstream.io/chat/docs/javascript/send_reaction/?language=javascript) and the associated emoji
|
|
3618
3618
|
*
|
|
3619
|
-
* You can provide any string as a reaction. The emoji can be provided as a string, if you want to use custom images for reactions you have to provide a [custom reactions UI](
|
|
3619
|
+
* You can provide any string as a reaction. The emoji can be provided as a string, if you want to use custom images for reactions you have to provide a [custom reactions UI](/chat/docs/sdk/angular/services/CustomTemplatesService/#messagereactionstemplate/)
|
|
3620
3620
|
*/
|
|
3621
3621
|
this.reactions$ = new BehaviorSubject({
|
|
3622
3622
|
haha: '😂',
|
|
@@ -3673,7 +3673,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.0.4", ngImpor
|
|
|
3673
3673
|
}], ctorParameters: function () { return [{ type: ChatClientService }, { type: NotificationService }]; } });
|
|
3674
3674
|
|
|
3675
3675
|
/**
|
|
3676
|
-
* The `MessageReactionsSelectorComponent` makes it possible for users to react to a message, the reaction options can be set using the [`MessageReactionsService`](
|
|
3676
|
+
* The `MessageReactionsSelectorComponent` makes it possible for users to react to a message, the reaction options can be set using the [`MessageReactionsService`](/chat/docs/sdk/angular/services/MessageReactionsService/). You can read more about [message reactions](https://getstream.io/chat/docs/javascript/send_reaction/?language=javascript) in the platform documentation.
|
|
3677
3677
|
*/
|
|
3678
3678
|
class MessageReactionsSelectorComponent {
|
|
3679
3679
|
constructor(channelService, messageReactionsService, cdRef) {
|
|
@@ -3681,7 +3681,7 @@ class MessageReactionsSelectorComponent {
|
|
|
3681
3681
|
this.messageReactionsService = messageReactionsService;
|
|
3682
3682
|
this.cdRef = cdRef;
|
|
3683
3683
|
/**
|
|
3684
|
-
* List of the user's own reactions of a [message](
|
|
3684
|
+
* List of the user's own reactions of a [message](/chat/docs/sdk/angular/types/stream-message/), used to display the users of a reaction type.
|
|
3685
3685
|
*/
|
|
3686
3686
|
this.ownReactions = [];
|
|
3687
3687
|
this.reactionOptions = [];
|
|
@@ -3731,7 +3731,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.0.4", ngImpor
|
|
|
3731
3731
|
}] } });
|
|
3732
3732
|
|
|
3733
3733
|
/**
|
|
3734
|
-
* The `MessageActionsBox` component displays a list of message actions (i.e edit), that can be opened or closed. You can find the [list of the supported actions](
|
|
3734
|
+
* The `MessageActionsBox` component displays a list of message actions (i.e edit), that can be opened or closed. You can find the [list of the supported actions](/chat/docs/sdk/angular/concepts/message-interactions/) in the message interaction guide.
|
|
3735
3735
|
*/
|
|
3736
3736
|
class MessageActionsBoxComponent {
|
|
3737
3737
|
constructor(customTemplatesService, messageActionsService, cdRef) {
|
|
@@ -3743,7 +3743,7 @@ class MessageActionsBoxComponent {
|
|
|
3743
3743
|
*/
|
|
3744
3744
|
this.isMine = false;
|
|
3745
3745
|
/**
|
|
3746
|
-
* The list of [channel capabilities](https://getstream.io/chat/docs/javascript/channel_capabilities/?language=javascript) that are enabled for the current user, the list of [supported interactions](
|
|
3746
|
+
* The list of [channel capabilities](https://getstream.io/chat/docs/javascript/channel_capabilities/?language=javascript) that are enabled for the current user, the list of [supported interactions](/chat/docs/sdk/angular/concepts/message-interactions) can be found in our message interaction guide. Unathorized actions won't be displayed on the UI.
|
|
3747
3747
|
*/
|
|
3748
3748
|
this.enabledActions = [];
|
|
3749
3749
|
this.visibleMessageActionItems = [];
|
|
@@ -3849,7 +3849,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.0.4", ngImpor
|
|
|
3849
3849
|
}] } });
|
|
3850
3850
|
|
|
3851
3851
|
/**
|
|
3852
|
-
* The `Notification` component displays a notification within the [`NotificationList`](
|
|
3852
|
+
* The `Notification` component displays a notification within the [`NotificationList`](/chat/docs/sdk/angular/components/NotificationListComponent/)
|
|
3853
3853
|
*/
|
|
3854
3854
|
class NotificationComponent {
|
|
3855
3855
|
constructor() { }
|
|
@@ -3957,7 +3957,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.0.4", ngImpor
|
|
|
3957
3957
|
}] } });
|
|
3958
3958
|
|
|
3959
3959
|
/**
|
|
3960
|
-
* The component watches for the [`channelService.bouncedMessage$` stream](
|
|
3960
|
+
* The component watches for the [`channelService.bouncedMessage$` stream](/chat/docs/sdk/angular/services/ChannelService/#bouncedmessage) and opens the bounce modal if a message is emitted.
|
|
3961
3961
|
*
|
|
3962
3962
|
* To bounce messages, you need to set up [semantic filters for moderation](https://getstream.io/automated-moderation/docs/automod_configuration/?q=semantic%20filters).
|
|
3963
3963
|
*/
|
|
@@ -4024,7 +4024,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.0.4", ngImpor
|
|
|
4024
4024
|
}] } });
|
|
4025
4025
|
|
|
4026
4026
|
/**
|
|
4027
|
-
* The `Channel` component is a container component that displays the [`ChannelHeader`](
|
|
4027
|
+
* The `Channel` component is a container component that displays the [`ChannelHeader`](/chat/docs/sdk/angular/components/ChannelHeaderComponent/), [`MessageList`](/chat/docs/sdk/angular/components/MessageListComponent), [`NotificationList`](/chat/docs/sdk/angular/components/NotificationListComponent/) and [`MessageInput`](/chat/docs/sdk/angular/components/MessageInputComponent/) components. You can also provide the [`Thread`](/chat/docs/sdk/angular/components/ThreadComponent/) component to use message [threads](https://getstream.io/chat/docs/javascript/threads/?language=javascript).
|
|
4028
4028
|
*/
|
|
4029
4029
|
class ChannelComponent {
|
|
4030
4030
|
constructor(channelService, themeService, customTemplatesService) {
|
|
@@ -5070,12 +5070,12 @@ class MessageReactionsComponent {
|
|
|
5070
5070
|
*/
|
|
5071
5071
|
this.messageReactionCounts = {};
|
|
5072
5072
|
/**
|
|
5073
|
-
* List of reactions of a [message](
|
|
5073
|
+
* List of reactions of a [message](/chat/docs/sdk/angular/types/stream-message/), used to display the users of a reaction type.
|
|
5074
5074
|
* @deprecated you can fetch the reactions using [`messageReactionsService.queryReactions()`](https://getstream.io/chat/docs/sdk/angular/services/MessageReactionsService/#queryreactions)
|
|
5075
5075
|
*/
|
|
5076
5076
|
this.latestReactions = [];
|
|
5077
5077
|
/**
|
|
5078
|
-
* List of the user's own reactions of a [message](
|
|
5078
|
+
* List of the user's own reactions of a [message](/chat/docs/sdk/angular/types/stream-message/), used to display the users of a reaction type.
|
|
5079
5079
|
*/
|
|
5080
5080
|
this.ownReactions = [];
|
|
5081
5081
|
this.isLoading = true;
|
|
@@ -5220,7 +5220,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.0.4", ngImpor
|
|
|
5220
5220
|
}] } });
|
|
5221
5221
|
|
|
5222
5222
|
/**
|
|
5223
|
-
* The `Message` component displays a message with additional information such as sender and date, and enables [interaction with the message (i.e. edit or react)](
|
|
5223
|
+
* The `Message` component displays a message with additional information such as sender and date, and enables [interaction with the message (i.e. edit or react)](/chat/docs/sdk/angular/concepts/message-interactions/).
|
|
5224
5224
|
*/
|
|
5225
5225
|
class MessageComponent {
|
|
5226
5226
|
constructor(chatClientService, channelService, customTemplatesService, cdRef, dateParser, messageService, messageActionsService, ngZone, translateService) {
|
|
@@ -5234,7 +5234,7 @@ class MessageComponent {
|
|
|
5234
5234
|
this.ngZone = ngZone;
|
|
5235
5235
|
this.translateService = translateService;
|
|
5236
5236
|
/**
|
|
5237
|
-
* The list of [channel capabilities](https://getstream.io/chat/docs/javascript/channel_capabilities/?language=javascript) that are enabled for the current user, the list of [supported interactions](
|
|
5237
|
+
* The list of [channel capabilities](https://getstream.io/chat/docs/javascript/channel_capabilities/?language=javascript) that are enabled for the current user, the list of [supported interactions](/chat/docs/sdk/angular/concepts/message-interactions/) can be found in our message interaction guide. Unathorized actions won't be displayed on the UI. The [`MessageList`](/chat/docs/sdk/angular/components/MessageListComponent/) component automatically sets this based on [channel capabilities](https://getstream.io/chat/docs/javascript/channel_capabilities/?language=javascript).
|
|
5238
5238
|
*/
|
|
5239
5239
|
this.enabledMessageActions = [];
|
|
5240
5240
|
/**
|
|
@@ -5851,12 +5851,12 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.0.4", ngImpor
|
|
|
5851
5851
|
}] } });
|
|
5852
5852
|
|
|
5853
5853
|
/**
|
|
5854
|
-
* If you have an emoji picker in your application, you can propagate the selected emoji to the textarea using this service, more info can be found in [custom emoji picker guide](
|
|
5854
|
+
* If you have an emoji picker in your application, you can propagate the selected emoji to the textarea using this service, more info can be found in [custom emoji picker guide](/chat/docs/sdk/angular/code-examples/emoji-picker/)
|
|
5855
5855
|
*/
|
|
5856
5856
|
class EmojiInputService {
|
|
5857
5857
|
constructor() {
|
|
5858
5858
|
/**
|
|
5859
|
-
* If you have an emoji picker in your application, you can propagate the selected emoji to the textarea using this Subject, more info can be found in [custom emoji picker guide](
|
|
5859
|
+
* If you have an emoji picker in your application, you can propagate the selected emoji to the textarea using this Subject, more info can be found in [custom emoji picker guide](/chat/docs/sdk/angular/code-examples/emoji-picker/)
|
|
5860
5860
|
*/
|
|
5861
5861
|
this.emojiInput$ = new Subject();
|
|
5862
5862
|
}
|
|
@@ -5895,7 +5895,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.0.4", ngImpor
|
|
|
5895
5895
|
}], ctorParameters: function () { return []; } });
|
|
5896
5896
|
|
|
5897
5897
|
/**
|
|
5898
|
-
* The `MessageInputConfigService` is used to keep a consistent configuration among the different [`MessageInput`](
|
|
5898
|
+
* The `MessageInputConfigService` is used to keep a consistent configuration among the different [`MessageInput`](/chat/docs/sdk/angular/components/MessageInputComponent/) components if your UI has more than one input component.
|
|
5899
5899
|
*/
|
|
5900
5900
|
class MessageInputConfigService {
|
|
5901
5901
|
constructor() {
|
|
@@ -5904,7 +5904,7 @@ class MessageInputConfigService {
|
|
|
5904
5904
|
*/
|
|
5905
5905
|
this.isFileUploadEnabled = true;
|
|
5906
5906
|
/**
|
|
5907
|
-
* If true, users can mention other users in messages. You also [need to use the `AutocompleteTextarea`](
|
|
5907
|
+
* If true, users can mention other users in messages. You also [need to use the `AutocompleteTextarea`](/chat/docs/sdk/angular/concepts/opt-in-architecture/) for this feature to work.
|
|
5908
5908
|
*/
|
|
5909
5909
|
this.areMentionsEnabled = true;
|
|
5910
5910
|
/**
|
|
@@ -5924,6 +5924,12 @@ class MessageInputConfigService {
|
|
|
5924
5924
|
* If `false`, the recording will added to the attachment preview, and users can continue composing the message.
|
|
5925
5925
|
*/
|
|
5926
5926
|
this.sendVoiceRecordingImmediately = true;
|
|
5927
|
+
/**
|
|
5928
|
+
* Add custom autocomplete configurations to the message input
|
|
5929
|
+
*
|
|
5930
|
+
* Only works when using StreamAutocompleteTextareaModule
|
|
5931
|
+
*/
|
|
5932
|
+
this.customAutocompletes$ = new BehaviorSubject([]);
|
|
5927
5933
|
}
|
|
5928
5934
|
}
|
|
5929
5935
|
MessageInputConfigService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.0.4", ngImport: i0, type: MessageInputConfigService, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
|
|
@@ -6526,7 +6532,7 @@ class MessageInputComponent {
|
|
|
6526
6532
|
*/
|
|
6527
6533
|
this.autoFocus = true;
|
|
6528
6534
|
/**
|
|
6529
|
-
* By default the input will react to changes in `messageToEdit$` from [`MessageActionsService`](
|
|
6535
|
+
* By default the input will react to changes in `messageToEdit$` from [`MessageActionsService`](/chat/docs/sdk/angular/services/MessageActionsService/) and display the message to be edited (taking into account the current `mode`).
|
|
6530
6536
|
*
|
|
6531
6537
|
* If you don't need that behavior, you can turn this of with this flag. In that case you should create your own edit message UI.
|
|
6532
6538
|
*/
|
|
@@ -6987,7 +6993,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.0.4", ngImpor
|
|
|
6987
6993
|
}] } });
|
|
6988
6994
|
|
|
6989
6995
|
/**
|
|
6990
|
-
* The `Textarea` component is used by the [`MessageInput`](
|
|
6996
|
+
* The `Textarea` component is used by the [`MessageInput`](/chat/docs/sdk/angular/components/MessageInputComponent/) component to display the input HTML element where users can type their message.
|
|
6991
6997
|
*/
|
|
6992
6998
|
class TextareaComponent {
|
|
6993
6999
|
constructor(emojiInputService) {
|
|
@@ -7117,16 +7123,17 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.0.4", ngImpor
|
|
|
7117
7123
|
}], ctorParameters: function () { return []; } });
|
|
7118
7124
|
|
|
7119
7125
|
/**
|
|
7120
|
-
* The `AutocompleteTextarea` component is used by the [`MessageInput`](
|
|
7126
|
+
* The `AutocompleteTextarea` component is used by the [`MessageInput`](/chat/docs/sdk/angular/components/MessageInputComponent/) component to display the input HTML element where users can type their message.
|
|
7121
7127
|
*/
|
|
7122
7128
|
class AutocompleteTextareaComponent {
|
|
7123
|
-
constructor(channelService, chatClientService, transliterationService, emojiInputService, customTemplatesService, cdRef) {
|
|
7129
|
+
constructor(channelService, chatClientService, transliterationService, emojiInputService, customTemplatesService, cdRef, messageInputConfigService) {
|
|
7124
7130
|
this.channelService = channelService;
|
|
7125
7131
|
this.chatClientService = chatClientService;
|
|
7126
7132
|
this.transliterationService = transliterationService;
|
|
7127
7133
|
this.emojiInputService = emojiInputService;
|
|
7128
7134
|
this.customTemplatesService = customTemplatesService;
|
|
7129
7135
|
this.cdRef = cdRef;
|
|
7136
|
+
this.messageInputConfigService = messageInputConfigService;
|
|
7130
7137
|
this.class = 'str-chat__textarea str-chat__message-textarea-angular-host';
|
|
7131
7138
|
/**
|
|
7132
7139
|
* The value of the input HTML element.
|
|
@@ -7137,11 +7144,11 @@ class AutocompleteTextareaComponent {
|
|
|
7137
7144
|
*/
|
|
7138
7145
|
this.placeholder = '';
|
|
7139
7146
|
/**
|
|
7140
|
-
* If true, users can mention other users in messages. You can also set this input on the [`MessageInput`](
|
|
7147
|
+
* If true, users can mention other users in messages. You can also set this input on the [`MessageInput`](/chat/docs/sdk/angular/components/MessageInputComponent/#inputs-and-outputs/) component.
|
|
7141
7148
|
*/
|
|
7142
7149
|
this.areMentionsEnabled = true;
|
|
7143
7150
|
/**
|
|
7144
|
-
* The scope for user mentions, either members of the current channel of members of the application. You can also set this input on the [`MessageInput`](
|
|
7151
|
+
* The scope for user mentions, either members of the current channel of members of the application. You can also set this input on the [`MessageInput`](/chat/docs/sdk/angular/components/MessageInputComponent/#inputs-and-outputs) component.
|
|
7145
7152
|
*/
|
|
7146
7153
|
this.mentionScope = 'channel';
|
|
7147
7154
|
/**
|
|
@@ -7175,6 +7182,7 @@ class AutocompleteTextareaComponent {
|
|
|
7175
7182
|
this.userMentionConfig = {
|
|
7176
7183
|
triggerChar: this.mentionTriggerChar,
|
|
7177
7184
|
dropUp: true,
|
|
7185
|
+
allowSpace: true,
|
|
7178
7186
|
labelKey: this.autocompleteKey,
|
|
7179
7187
|
returnTrigger: true,
|
|
7180
7188
|
mentionFilter: (searchString, items) => this.filter(searchString, items),
|
|
@@ -7190,10 +7198,15 @@ class AutocompleteTextareaComponent {
|
|
|
7190
7198
|
};
|
|
7191
7199
|
this.searchTerm$ = new BehaviorSubject('');
|
|
7192
7200
|
this.isViewInited = false;
|
|
7193
|
-
this.searchTerm
|
|
7201
|
+
this.searchTerm$
|
|
7202
|
+
.pipe(filter((searchTerm) => searchTerm.length !== 1), debounceTime(300))
|
|
7203
|
+
.subscribe((searchTerm) => {
|
|
7194
7204
|
if (searchTerm.startsWith(this.mentionTriggerChar)) {
|
|
7195
7205
|
void this.updateMentionOptions(searchTerm);
|
|
7196
7206
|
}
|
|
7207
|
+
else {
|
|
7208
|
+
void this.updateCustomAutocompleteOptions(searchTerm);
|
|
7209
|
+
}
|
|
7197
7210
|
});
|
|
7198
7211
|
this.subscriptions.push(this.channelService.activeChannel$.subscribe((channel) => {
|
|
7199
7212
|
var _a;
|
|
@@ -7202,6 +7215,7 @@ class AutocompleteTextareaComponent {
|
|
|
7202
7215
|
this.mentionedUsers = [];
|
|
7203
7216
|
this.userMentions.next([...this.mentionedUsers]);
|
|
7204
7217
|
void this.updateMentionOptions(this.searchTerm$.getValue());
|
|
7218
|
+
void this.updateCustomAutocompleteOptions(this.searchTerm$.getValue());
|
|
7205
7219
|
}));
|
|
7206
7220
|
this.subscriptions.push(this.emojiInputService.emojiInput$.subscribe((emoji) => {
|
|
7207
7221
|
this.messageInput.nativeElement.focus();
|
|
@@ -7219,35 +7233,56 @@ class AutocompleteTextareaComponent {
|
|
|
7219
7233
|
this.userMentionConfig,
|
|
7220
7234
|
this.slashCommandConfig,
|
|
7221
7235
|
];
|
|
7236
|
+
this.subscriptions.push(this.messageInputConfigService.customAutocompletes$.subscribe((customConfigs) => {
|
|
7237
|
+
var _a, _b;
|
|
7238
|
+
const builtInItems = (_b = (_a = this.autocompleteConfig.mentions) === null || _a === void 0 ? void 0 : _a.filter((m) => m === this.userMentionConfig || m === this.slashCommandConfig)) !== null && _b !== void 0 ? _b : [];
|
|
7239
|
+
const transformedCustomConfigs = customConfigs.map((c) => {
|
|
7240
|
+
const copy = {
|
|
7241
|
+
items: c.options.map((o) => (Object.assign(Object.assign({}, o), { templateRef: c.templateRef }))),
|
|
7242
|
+
triggerChar: c.triggerCharacter,
|
|
7243
|
+
dropUp: true,
|
|
7244
|
+
labelKey: this.autocompleteKey,
|
|
7245
|
+
returnTrigger: true,
|
|
7246
|
+
allowSpace: c.allowSpace,
|
|
7247
|
+
mentionFilter: (searchString, items) => this.filter(searchString, items),
|
|
7248
|
+
mentionSelect: (item, triggerChar) => this.itemSelectedFromAutocompleteList(item, triggerChar),
|
|
7249
|
+
};
|
|
7250
|
+
return copy;
|
|
7251
|
+
});
|
|
7252
|
+
this.autocompleteConfig.mentions = [
|
|
7253
|
+
...builtInItems,
|
|
7254
|
+
...transformedCustomConfigs,
|
|
7255
|
+
];
|
|
7256
|
+
this.autocompleteConfig = Object.assign({}, this.autocompleteConfig);
|
|
7257
|
+
}));
|
|
7222
7258
|
}
|
|
7223
7259
|
ngOnChanges(changes) {
|
|
7224
|
-
var _a, _b, _c, _d, _e, _f;
|
|
7260
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j;
|
|
7225
7261
|
if (changes.areMentionsEnabled) {
|
|
7226
|
-
|
|
7227
|
-
this.autocompleteConfig.mentions
|
|
7228
|
-
this.userMentionConfig
|
|
7229
|
-
|
|
7230
|
-
|
|
7231
|
-
|
|
7232
|
-
|
|
7233
|
-
|
|
7234
|
-
|
|
7235
|
-
|
|
7236
|
-
}
|
|
7262
|
+
this.autocompleteConfig.mentions =
|
|
7263
|
+
(_c = (_b = (_a = this.autocompleteConfig) === null || _a === void 0 ? void 0 : _a.mentions) === null || _b === void 0 ? void 0 : _b.filter((c) => {
|
|
7264
|
+
if (c !== this.userMentionConfig) {
|
|
7265
|
+
return true;
|
|
7266
|
+
}
|
|
7267
|
+
else {
|
|
7268
|
+
return this.areMentionsEnabled;
|
|
7269
|
+
}
|
|
7270
|
+
})) !== null && _c !== void 0 ? _c : [];
|
|
7271
|
+
this.autocompleteConfig = Object.assign({}, this.autocompleteConfig);
|
|
7237
7272
|
}
|
|
7238
7273
|
if (changes.mentionScope) {
|
|
7239
7274
|
void this.updateMentionOptions(this.searchTerm$.getValue());
|
|
7240
7275
|
}
|
|
7241
7276
|
if (changes.value && !this.value && this.messageInput) {
|
|
7242
7277
|
this.messageInput.nativeElement.style.height = 'auto';
|
|
7243
|
-
(
|
|
7278
|
+
(_f = (_e = (_d = this.chatClientService) === null || _d === void 0 ? void 0 : _d.chatClient) === null || _e === void 0 ? void 0 : _e.logger) === null || _f === void 0 ? void 0 : _f.call(_e, 'info', '[Autocomplete textarea] Value reset, adjusting textarea height to auto');
|
|
7244
7279
|
this.updateMentionedUsersFromText();
|
|
7245
7280
|
}
|
|
7246
7281
|
else if (changes.value &&
|
|
7247
7282
|
this.value &&
|
|
7248
7283
|
this.messageInput &&
|
|
7249
7284
|
this.isViewInited) {
|
|
7250
|
-
(
|
|
7285
|
+
(_j = (_h = (_g = this.chatClientService) === null || _g === void 0 ? void 0 : _g.chatClient) === null || _h === void 0 ? void 0 : _h.logger) === null || _j === void 0 ? void 0 : _j.call(_h, 'info', '[Autocomplete textarea] Value changed');
|
|
7251
7286
|
setTimeout(() => {
|
|
7252
7287
|
if (this.messageInput.nativeElement.scrollHeight > 0) {
|
|
7253
7288
|
this.adjustTextareaHeight();
|
|
@@ -7271,15 +7306,19 @@ class AutocompleteTextareaComponent {
|
|
|
7271
7306
|
this.mentionedUsers.push((item.user ? item.user : item));
|
|
7272
7307
|
this.userMentions.next([...this.mentionedUsers]);
|
|
7273
7308
|
}
|
|
7309
|
+
this.searchTerm$.next('');
|
|
7274
7310
|
return triggerChar + item.autocompleteLabel + ' ';
|
|
7275
7311
|
}
|
|
7276
7312
|
autcompleteSearchTermChanged(searchTerm) {
|
|
7277
|
-
if (searchTerm ===
|
|
7278
|
-
|
|
7279
|
-
|
|
7280
|
-
|
|
7281
|
-
|
|
7313
|
+
if (searchTerm.length === 1) {
|
|
7314
|
+
if (searchTerm === this.mentionTriggerChar) {
|
|
7315
|
+
void this.updateMentionOptions();
|
|
7316
|
+
}
|
|
7317
|
+
else {
|
|
7318
|
+
void this.updateCustomAutocompleteOptions(searchTerm);
|
|
7319
|
+
}
|
|
7282
7320
|
}
|
|
7321
|
+
this.searchTerm$.next(searchTerm);
|
|
7283
7322
|
}
|
|
7284
7323
|
inputChanged() {
|
|
7285
7324
|
var _a, _b, _c;
|
|
@@ -7312,6 +7351,7 @@ class AutocompleteTextareaComponent {
|
|
|
7312
7351
|
}
|
|
7313
7352
|
}
|
|
7314
7353
|
updateMentionOptions(searchTerm) {
|
|
7354
|
+
var _a, _b;
|
|
7315
7355
|
return __awaiter(this, void 0, void 0, function* () {
|
|
7316
7356
|
if (!this.areMentionsEnabled) {
|
|
7317
7357
|
return;
|
|
@@ -7327,8 +7367,7 @@ class AutocompleteTextareaComponent {
|
|
|
7327
7367
|
}));
|
|
7328
7368
|
this.userMentionConfig.items = items;
|
|
7329
7369
|
this.autocompleteConfig.mentions = [
|
|
7330
|
-
this.
|
|
7331
|
-
this.slashCommandConfig,
|
|
7370
|
+
...((_b = (_a = this.autocompleteConfig) === null || _a === void 0 ? void 0 : _a.mentions) !== null && _b !== void 0 ? _b : []),
|
|
7332
7371
|
];
|
|
7333
7372
|
this.autocompleteConfig = Object.assign({}, this.autocompleteConfig);
|
|
7334
7373
|
this.cdRef.detectChanges();
|
|
@@ -7347,13 +7386,33 @@ class AutocompleteTextareaComponent {
|
|
|
7347
7386
|
this.mentionedUsers = updatedMentionedUsers;
|
|
7348
7387
|
}
|
|
7349
7388
|
}
|
|
7389
|
+
updateCustomAutocompleteOptions(searchTerm) {
|
|
7390
|
+
var _a;
|
|
7391
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
7392
|
+
if (this.messageInputConfigService.customAutocompletes$.getValue().length ===
|
|
7393
|
+
0) {
|
|
7394
|
+
return;
|
|
7395
|
+
}
|
|
7396
|
+
const customMentionConfig = (_a = this.autocompleteConfig.mentions) === null || _a === void 0 ? void 0 : _a.find((c) => c.triggerChar && searchTerm.startsWith(c.triggerChar));
|
|
7397
|
+
const customAutocompleteConfig = customMentionConfig
|
|
7398
|
+
? this.messageInputConfigService.customAutocompletes$
|
|
7399
|
+
.getValue()
|
|
7400
|
+
.find((c) => c.triggerCharacter === (customMentionConfig === null || customMentionConfig === void 0 ? void 0 : customMentionConfig.triggerChar))
|
|
7401
|
+
: undefined;
|
|
7402
|
+
if (customMentionConfig && (customAutocompleteConfig === null || customAutocompleteConfig === void 0 ? void 0 : customAutocompleteConfig.updateOptions)) {
|
|
7403
|
+
const newOptions = yield customAutocompleteConfig.updateOptions(searchTerm.replace(customMentionConfig.triggerChar || '', ''));
|
|
7404
|
+
customMentionConfig.items = newOptions.map((o) => (Object.assign(Object.assign({}, o), { templateRef: customAutocompleteConfig.templateRef })));
|
|
7405
|
+
this.autocompleteConfig = Object.assign({}, this.autocompleteConfig);
|
|
7406
|
+
}
|
|
7407
|
+
});
|
|
7408
|
+
}
|
|
7350
7409
|
}
|
|
7351
|
-
AutocompleteTextareaComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.0.4", ngImport: i0, type: AutocompleteTextareaComponent, deps: [{ token: ChannelService }, { token: ChatClientService }, { token: TransliterationService }, { token: EmojiInputService }, { token: CustomTemplatesService }, { token: i0.ChangeDetectorRef }], target: i0.ɵɵFactoryTarget.Component });
|
|
7352
|
-
AutocompleteTextareaComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.0.4", type: AutocompleteTextareaComponent, selector: "stream-autocomplete-textarea", inputs: { value: "value", placeholder: "placeholder", areMentionsEnabled: "areMentionsEnabled", inputMode: "inputMode", mentionScope: "mentionScope", autoFocus: "autoFocus" }, outputs: { valueChange: "valueChange", send: "send", userMentions: "userMentions", pasteFromClipboard: "pasteFromClipboard" }, host: { properties: { "class": "this.class" } }, viewQueries: [{ propertyName: "messageInput", first: true, predicate: ["input"], descendants: true }], usesOnChanges: true, ngImport: i0, template: "<textarea\n #input\n data-testid=\"textarea\"\n class=\"rta__textarea str-chat__textarea__textarea str-chat__angular-textarea str-chat__message-textarea\"\n rows=\"1\"\n [value]=\"value || ''\"\n [autofocus]=\"autoFocus\"\n placeholder=\"{{ placeholder | translate }}\"\n [mentionConfig]=\"autocompleteConfig\"\n [mentionListTemplate]=\"autocompleteItem\"\n (input)=\"inputChanged()\"\n (keydown.enter)=\"enterHit($event)\"\n (searchTerm)=\"autcompleteSearchTermChanged($event)\"\n (blur)=\"inputLeft()\"\n (paste)=\"pasteFromClipboard.emit($event)\"\n></textarea>\n<ng-template #autocompleteItem let-item=\"item\">\n <div
|
|
7410
|
+
AutocompleteTextareaComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.0.4", ngImport: i0, type: AutocompleteTextareaComponent, deps: [{ token: ChannelService }, { token: ChatClientService }, { token: TransliterationService }, { token: EmojiInputService }, { token: CustomTemplatesService }, { token: i0.ChangeDetectorRef }, { token: MessageInputConfigService }], target: i0.ɵɵFactoryTarget.Component });
|
|
7411
|
+
AutocompleteTextareaComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.0.4", type: AutocompleteTextareaComponent, selector: "stream-autocomplete-textarea", inputs: { value: "value", placeholder: "placeholder", areMentionsEnabled: "areMentionsEnabled", inputMode: "inputMode", mentionScope: "mentionScope", autoFocus: "autoFocus" }, outputs: { valueChange: "valueChange", send: "send", userMentions: "userMentions", pasteFromClipboard: "pasteFromClipboard" }, host: { properties: { "class": "this.class" } }, viewQueries: [{ propertyName: "messageInput", first: true, predicate: ["input"], descendants: true }], usesOnChanges: true, ngImport: i0, template: "<textarea\n #input\n data-testid=\"textarea\"\n class=\"rta__textarea str-chat__textarea__textarea str-chat__angular-textarea str-chat__message-textarea\"\n rows=\"1\"\n [value]=\"value || ''\"\n [autofocus]=\"autoFocus\"\n placeholder=\"{{ placeholder | translate }}\"\n [mentionConfig]=\"autocompleteConfig\"\n [mentionListTemplate]=\"autocompleteItem\"\n (input)=\"inputChanged()\"\n (keydown.enter)=\"enterHit($event)\"\n (searchTerm)=\"autcompleteSearchTermChanged($event)\"\n (blur)=\"inputLeft()\"\n (paste)=\"pasteFromClipboard.emit($event)\"\n></textarea>\n<ng-template #autocompleteItem let-item=\"item\">\n <ng-container *ngIf=\"item.templateRef; else builtinItem\">\n <ng-container\n *ngTemplateOutlet=\"item.templateRef; context: { item: item }\"\n ></ng-container>\n </ng-container>\n <ng-template #builtinItem>\n <div\n class=\"rta rta__item str-chat__emojisearch__item\"\n [ngSwitch]=\"item.type\"\n >\n <div *ngSwitchCase=\"'mention'\" class=\"rta__entity\">\n <ng-container\n *ngTemplateOutlet=\"\n mentionAutocompleteItemTemplate || defaultMentionTemplate;\n context: { item: item }\n \"\n ></ng-container>\n </div>\n <div *ngSwitchCase=\"'command'\" class=\"rta__entity\">\n <ng-container\n *ngTemplateOutlet=\"\n commandAutocompleteItemTemplate || defaultCommandTemplate;\n context: { item: item }\n \"\n ></ng-container>\n </div>\n </div>\n </ng-template>\n</ng-template>\n\n<ng-template #defaultCommandTemplate let-item=\"item\">\n <div class=\"str-chat__slash-command\">\n <span class=\"str-chat__slash-command-header\">\n <strong\n class=\"str-chat__slash-command-name\"\n data-testclass=\"command-name\"\n >{{ item.name }}</strong\n >\n <span class=\"str-chat__slash-command-args\"\n >/{{ item.name }} {{ item.args }}</span\n >\n </span>\n <br />\n </div>\n</ng-template>\n\n<ng-template #defaultMentionTemplate let-item=\"item\">\n <div class=\"str-chat__user-item\">\n <stream-avatar-placeholder\n data-testclass=\"avatar\"\n class=\"str-chat__avatar str-chat__avatar--circle\"\n type=\"user\"\n location=\"autocomplete-item\"\n [imageUrl]=\"item.image || item.user?.image\"\n [name]=\"item.autocompleteLabel\"\n [user]=\"item.user || item\"\n ></stream-avatar-placeholder>\n <span data-testclass=\"username\" class=\"str-chat__user-item--name\">{{\n item.autocompleteLabel\n }}</span>\n </div>\n</ng-template>\n", dependencies: [{ kind: "directive", type: i4.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i4.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "directive", type: i4.NgSwitch, selector: "[ngSwitch]", inputs: ["ngSwitch"] }, { kind: "directive", type: i4.NgSwitchCase, selector: "[ngSwitchCase]", inputs: ["ngSwitchCase"] }, { kind: "directive", type: i8.MentionDirective, selector: "[mention], [mentionConfig]", inputs: ["mentionConfig", "mention", "mentionListTemplate"], outputs: ["searchTerm", "itemSelected", "opened", "closed"] }, { kind: "component", type: AvatarPlaceholderComponent, selector: "stream-avatar-placeholder", inputs: ["name", "imageUrl", "location", "channel", "user", "type", "initialsType", "showOnlineIndicator"] }, { kind: "pipe", type: i7.TranslatePipe, name: "translate" }] });
|
|
7353
7412
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.0.4", ngImport: i0, type: AutocompleteTextareaComponent, decorators: [{
|
|
7354
7413
|
type: Component,
|
|
7355
|
-
args: [{ selector: 'stream-autocomplete-textarea', template: "<textarea\n #input\n data-testid=\"textarea\"\n class=\"rta__textarea str-chat__textarea__textarea str-chat__angular-textarea str-chat__message-textarea\"\n rows=\"1\"\n [value]=\"value || ''\"\n [autofocus]=\"autoFocus\"\n placeholder=\"{{ placeholder | translate }}\"\n [mentionConfig]=\"autocompleteConfig\"\n [mentionListTemplate]=\"autocompleteItem\"\n (input)=\"inputChanged()\"\n (keydown.enter)=\"enterHit($event)\"\n (searchTerm)=\"autcompleteSearchTermChanged($event)\"\n (blur)=\"inputLeft()\"\n (paste)=\"pasteFromClipboard.emit($event)\"\n></textarea>\n<ng-template #autocompleteItem let-item=\"item\">\n <div
|
|
7356
|
-
}], ctorParameters: function () { return [{ type: ChannelService }, { type: ChatClientService }, { type: TransliterationService }, { type: EmojiInputService }, { type: CustomTemplatesService }, { type: i0.ChangeDetectorRef }]; }, propDecorators: { class: [{
|
|
7414
|
+
args: [{ selector: 'stream-autocomplete-textarea', template: "<textarea\n #input\n data-testid=\"textarea\"\n class=\"rta__textarea str-chat__textarea__textarea str-chat__angular-textarea str-chat__message-textarea\"\n rows=\"1\"\n [value]=\"value || ''\"\n [autofocus]=\"autoFocus\"\n placeholder=\"{{ placeholder | translate }}\"\n [mentionConfig]=\"autocompleteConfig\"\n [mentionListTemplate]=\"autocompleteItem\"\n (input)=\"inputChanged()\"\n (keydown.enter)=\"enterHit($event)\"\n (searchTerm)=\"autcompleteSearchTermChanged($event)\"\n (blur)=\"inputLeft()\"\n (paste)=\"pasteFromClipboard.emit($event)\"\n></textarea>\n<ng-template #autocompleteItem let-item=\"item\">\n <ng-container *ngIf=\"item.templateRef; else builtinItem\">\n <ng-container\n *ngTemplateOutlet=\"item.templateRef; context: { item: item }\"\n ></ng-container>\n </ng-container>\n <ng-template #builtinItem>\n <div\n class=\"rta rta__item str-chat__emojisearch__item\"\n [ngSwitch]=\"item.type\"\n >\n <div *ngSwitchCase=\"'mention'\" class=\"rta__entity\">\n <ng-container\n *ngTemplateOutlet=\"\n mentionAutocompleteItemTemplate || defaultMentionTemplate;\n context: { item: item }\n \"\n ></ng-container>\n </div>\n <div *ngSwitchCase=\"'command'\" class=\"rta__entity\">\n <ng-container\n *ngTemplateOutlet=\"\n commandAutocompleteItemTemplate || defaultCommandTemplate;\n context: { item: item }\n \"\n ></ng-container>\n </div>\n </div>\n </ng-template>\n</ng-template>\n\n<ng-template #defaultCommandTemplate let-item=\"item\">\n <div class=\"str-chat__slash-command\">\n <span class=\"str-chat__slash-command-header\">\n <strong\n class=\"str-chat__slash-command-name\"\n data-testclass=\"command-name\"\n >{{ item.name }}</strong\n >\n <span class=\"str-chat__slash-command-args\"\n >/{{ item.name }} {{ item.args }}</span\n >\n </span>\n <br />\n </div>\n</ng-template>\n\n<ng-template #defaultMentionTemplate let-item=\"item\">\n <div class=\"str-chat__user-item\">\n <stream-avatar-placeholder\n data-testclass=\"avatar\"\n class=\"str-chat__avatar str-chat__avatar--circle\"\n type=\"user\"\n location=\"autocomplete-item\"\n [imageUrl]=\"item.image || item.user?.image\"\n [name]=\"item.autocompleteLabel\"\n [user]=\"item.user || item\"\n ></stream-avatar-placeholder>\n <span data-testclass=\"username\" class=\"str-chat__user-item--name\">{{\n item.autocompleteLabel\n }}</span>\n </div>\n</ng-template>\n" }]
|
|
7415
|
+
}], ctorParameters: function () { return [{ type: ChannelService }, { type: ChatClientService }, { type: TransliterationService }, { type: EmojiInputService }, { type: CustomTemplatesService }, { type: i0.ChangeDetectorRef }, { type: MessageInputConfigService }]; }, propDecorators: { class: [{
|
|
7357
7416
|
type: HostBinding
|
|
7358
7417
|
}], value: [{
|
|
7359
7418
|
type: Input
|
|
@@ -8484,7 +8543,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.0.4", ngImpor
|
|
|
8484
8543
|
}] } });
|
|
8485
8544
|
|
|
8486
8545
|
/**
|
|
8487
|
-
* The `Thread` component represents a [message thread](https://getstream.io/chat/docs/javascript/threads/?language=javascript), it is a container component that displays a thread with a header, [`MessageList`](
|
|
8546
|
+
* The `Thread` component represents a [message thread](https://getstream.io/chat/docs/javascript/threads/?language=javascript), it is a container component that displays a thread with a header, [`MessageList`](/chat/docs/sdk/angular/components/MessageListComponent) and [`MessageInput`](/chat/docs/sdk/angular/components/MessageInputComponent/) components.
|
|
8488
8547
|
*/
|
|
8489
8548
|
class ThreadComponent {
|
|
8490
8549
|
constructor(customTemplatesService, channelService, chatClientService) {
|