@progress/kendo-angular-conversational-ui 11.2.0-develop.9 → 11.3.0-develop.1
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/chat/l10n/messages.d.ts +10 -1
- package/chat/message-list.component.d.ts +9 -3
- package/chat/suggested-actions.component.d.ts +1 -2
- package/esm2020/cards/hero-card.component.mjs +3 -3
- package/esm2020/chat/attachment-template.directive.mjs +3 -3
- package/esm2020/chat/attachment.component.mjs +3 -3
- package/esm2020/chat/chat.component.mjs +47 -31
- package/esm2020/chat/chat.module.mjs +4 -4
- package/esm2020/chat/l10n/custom-messages.component.mjs +3 -3
- package/esm2020/chat/l10n/localized-messages.directive.mjs +3 -3
- package/esm2020/chat/l10n/messages.mjs +7 -3
- package/esm2020/chat/message-attachments.component.mjs +8 -7
- package/esm2020/chat/message-box.component.mjs +14 -10
- package/esm2020/chat/message-box.directive.mjs +3 -3
- package/esm2020/chat/message-list.component.mjs +51 -14
- package/esm2020/chat/message-template.directive.mjs +3 -3
- package/esm2020/chat/message.component.mjs +3 -3
- package/esm2020/chat/suggested-actions.component.mjs +17 -25
- package/esm2020/common/focused-state.directive.mjs +3 -3
- package/esm2020/common/scroll-anchor.directive.mjs +3 -3
- package/esm2020/package-metadata.mjs +2 -2
- package/fesm2015/progress-kendo-angular-conversational-ui.mjs +257 -211
- package/fesm2020/progress-kendo-angular-conversational-ui.mjs +254 -208
- package/package.json +7 -7
- package/common/keys.enum.d.ts +0 -14
- package/esm2020/common/keys.enum.mjs +0 -5
package/chat/l10n/messages.d.ts
CHANGED
|
@@ -16,6 +16,15 @@ export declare class Messages extends ComponentMessages {
|
|
|
16
16
|
* Sets the text for the **Send** button.
|
|
17
17
|
*/
|
|
18
18
|
send: string;
|
|
19
|
+
/**
|
|
20
|
+
* The label for the Message list.
|
|
21
|
+
*/
|
|
22
|
+
messageListLabel: string;
|
|
23
|
+
/**
|
|
24
|
+
* The label for the Message input box.
|
|
25
|
+
*
|
|
26
|
+
*/
|
|
27
|
+
messageBoxInputLabel: string;
|
|
19
28
|
static ɵfac: i0.ɵɵFactoryDeclaration<Messages, never>;
|
|
20
|
-
static ɵdir: i0.ɵɵDirectiveDeclaration<Messages, "kendoConversationalUIMessages", never, { "messagePlaceholder": "messagePlaceholder"; "send": "send"; }, {}, never>;
|
|
29
|
+
static ɵdir: i0.ɵɵDirectiveDeclaration<Messages, "kendoConversationalUIMessages", never, { "messagePlaceholder": "messagePlaceholder"; "send": "send"; "messageListLabel": "messageListLabel"; "messageBoxInputLabel": "messageBoxInputLabel"; }, {}, never>;
|
|
21
30
|
}
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
* Copyright © 2023 Progress Software Corporation. All rights reserved.
|
|
3
3
|
* Licensed under commercial license. See LICENSE.md in the project root for more information
|
|
4
4
|
*-------------------------------------------------------------------------------------------*/
|
|
5
|
-
import { AfterViewInit, ElementRef, EventEmitter, QueryList } from '@angular/core';
|
|
5
|
+
import { AfterViewInit, ElementRef, EventEmitter, OnDestroy, OnInit, QueryList, Renderer2 } from '@angular/core';
|
|
6
6
|
import { Action, ExecuteActionEvent, Message, User } from '../api';
|
|
7
7
|
import { ChatItem } from './chat-item';
|
|
8
8
|
import { ViewItem } from './chat-view';
|
|
@@ -13,9 +13,10 @@ import * as i0 from "@angular/core";
|
|
|
13
13
|
/**
|
|
14
14
|
* @hidden
|
|
15
15
|
*/
|
|
16
|
-
export declare class MessageListComponent implements AfterViewInit {
|
|
16
|
+
export declare class MessageListComponent implements OnInit, AfterViewInit, OnDestroy {
|
|
17
17
|
private element;
|
|
18
18
|
private intl;
|
|
19
|
+
private renderer;
|
|
19
20
|
set messages(value: Message[]);
|
|
20
21
|
get messages(): Message[];
|
|
21
22
|
attachmentTemplate: AttachmentTemplateDirective;
|
|
@@ -28,10 +29,13 @@ export declare class MessageListComponent implements AfterViewInit {
|
|
|
28
29
|
cssClass: boolean;
|
|
29
30
|
view: ViewItem[] | any[];
|
|
30
31
|
private _messages;
|
|
32
|
+
private subs;
|
|
31
33
|
private selectedItem;
|
|
32
34
|
private keyActions;
|
|
33
|
-
constructor(element: ElementRef, intl: IntlService);
|
|
35
|
+
constructor(element: ElementRef, intl: IntlService, renderer: Renderer2);
|
|
36
|
+
ngOnInit(): void;
|
|
34
37
|
ngAfterViewInit(): void;
|
|
38
|
+
ngOnDestroy(): void;
|
|
35
39
|
onResize(): void;
|
|
36
40
|
formatTimeStamp(date: any): string;
|
|
37
41
|
onKeydown(e: any): void;
|
|
@@ -41,6 +45,8 @@ export declare class MessageListComponent implements AfterViewInit {
|
|
|
41
45
|
trackGroup(_index: number, item: ViewItem): any;
|
|
42
46
|
select(item: ChatItem): void;
|
|
43
47
|
last(items: any): any;
|
|
48
|
+
private onHomeOrEndKeyDown;
|
|
49
|
+
private onTabKeyDown;
|
|
44
50
|
private navigateTo;
|
|
45
51
|
static ɵfac: i0.ɵɵFactoryDeclaration<MessageListComponent, never>;
|
|
46
52
|
static ɵcmp: i0.ɵɵComponentDeclaration<MessageListComponent, "kendo-chat-message-list", never, { "messages": "messages"; "attachmentTemplate": "attachmentTemplate"; "messageTemplate": "messageTemplate"; "user": "user"; }, { "executeAction": "executeAction"; "navigate": "navigate"; "resize": "resize"; }, never, never>;
|
|
@@ -22,8 +22,7 @@ export declare class SuggestedActionsComponent extends ChatItem {
|
|
|
22
22
|
actionClick(action: Action): void;
|
|
23
23
|
actionKeydown(e: any, action: Action): void;
|
|
24
24
|
focus(): void;
|
|
25
|
-
private
|
|
26
|
-
private navigateTo;
|
|
25
|
+
private changeSelectedIndex;
|
|
27
26
|
static ɵfac: i0.ɵɵFactoryDeclaration<SuggestedActionsComponent, never>;
|
|
28
27
|
static ɵcmp: i0.ɵɵComponentDeclaration<SuggestedActionsComponent, "kendo-chat-suggested-actions", never, { "actions": "actions"; "tabbable": "tabbable"; }, { "dispatch": "dispatch"; }, never, never>;
|
|
29
28
|
}
|
|
@@ -22,8 +22,8 @@ export class HeroCardComponent {
|
|
|
22
22
|
this.executeAction.next(action);
|
|
23
23
|
}
|
|
24
24
|
}
|
|
25
|
-
HeroCardComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.
|
|
26
|
-
HeroCardComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.3.
|
|
25
|
+
HeroCardComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.12", ngImport: i0, type: HeroCardComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
26
|
+
HeroCardComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.3.12", type: HeroCardComponent, selector: "kendo-chat-hero-card", inputs: { imageUrl: "imageUrl", title: "title", subtitle: "subtitle", actions: "actions" }, outputs: { executeAction: "executeAction" }, host: { properties: { "class.k-card": "this.cssClass" } }, ngImport: i0, template: `
|
|
27
27
|
<img class="k-card-image" [src]="imageUrl" *ngIf="imageUrl" />
|
|
28
28
|
<div class="k-card-body">
|
|
29
29
|
<h5 class="k-card-title" *ngIf="title">
|
|
@@ -46,7 +46,7 @@ HeroCardComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", vers
|
|
|
46
46
|
</span>
|
|
47
47
|
</div>
|
|
48
48
|
`, isInline: true, components: [{ type: i1.Button, selector: "button[kendoButton], span[kendoButton], kendo-button", inputs: ["toggleable", "togglable", "selected", "tabIndex", "imageUrl", "iconClass", "icon", "disabled", "size", "rounded", "fillMode", "themeColor", "svgIcon", "role", "primary", "look"], outputs: ["selectedChange", "click"], exportAs: ["kendoButton"] }], directives: [{ type: i2.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i2.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }] });
|
|
49
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.
|
|
49
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.12", ngImport: i0, type: HeroCardComponent, decorators: [{
|
|
50
50
|
type: Component,
|
|
51
51
|
args: [{
|
|
52
52
|
selector: 'kendo-chat-hero-card',
|
|
@@ -21,9 +21,9 @@ export class AttachmentTemplateDirective {
|
|
|
21
21
|
this.templateRef = templateRef;
|
|
22
22
|
}
|
|
23
23
|
}
|
|
24
|
-
AttachmentTemplateDirective.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.
|
|
25
|
-
AttachmentTemplateDirective.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "12.0.0", version: "13.3.
|
|
26
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.
|
|
24
|
+
AttachmentTemplateDirective.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.12", ngImport: i0, type: AttachmentTemplateDirective, deps: [{ token: i0.TemplateRef, optional: true }], target: i0.ɵɵFactoryTarget.Directive });
|
|
25
|
+
AttachmentTemplateDirective.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "12.0.0", version: "13.3.12", type: AttachmentTemplateDirective, selector: "[kendoChatAttachmentTemplate]", ngImport: i0 });
|
|
26
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.12", ngImport: i0, type: AttachmentTemplateDirective, decorators: [{
|
|
27
27
|
type: Directive,
|
|
28
28
|
args: [{
|
|
29
29
|
selector: '[kendoChatAttachmentTemplate]'
|
|
@@ -29,8 +29,8 @@ export class AttachmentComponent {
|
|
|
29
29
|
return this.attachment.contentType || '';
|
|
30
30
|
}
|
|
31
31
|
}
|
|
32
|
-
AttachmentComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.
|
|
33
|
-
AttachmentComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.3.
|
|
32
|
+
AttachmentComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.12", ngImport: i0, type: AttachmentComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
33
|
+
AttachmentComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.3.12", type: AttachmentComponent, selector: "kendo-chat-attachment", inputs: { attachment: "attachment", template: "template" }, ngImport: i0, template: `
|
|
34
34
|
<ng-container *ngIf="template">
|
|
35
35
|
<ng-container *ngTemplateOutlet="template.templateRef; context: context;">
|
|
36
36
|
</ng-container>
|
|
@@ -51,7 +51,7 @@ AttachmentComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", ve
|
|
|
51
51
|
</div>
|
|
52
52
|
</div>
|
|
53
53
|
`, isInline: true, directives: [{ type: i1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i1.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet"] }] });
|
|
54
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.
|
|
54
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.12", ngImport: i0, type: AttachmentComponent, decorators: [{
|
|
55
55
|
type: Component,
|
|
56
56
|
args: [{
|
|
57
57
|
selector: 'kendo-chat-attachment',
|
|
@@ -112,8 +112,8 @@ export class ChatComponent {
|
|
|
112
112
|
return this.localization.get(key);
|
|
113
113
|
}
|
|
114
114
|
}
|
|
115
|
-
ChatComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.
|
|
116
|
-
ChatComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.3.
|
|
115
|
+
ChatComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.12", ngImport: i0, type: ChatComponent, deps: [{ token: i1.LocalizationService }, { token: i0.NgZone }], target: i0.ɵɵFactoryTarget.Component });
|
|
116
|
+
ChatComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.3.12", type: ChatComponent, selector: "kendo-chat", inputs: { messages: "messages", user: "user", messageBoxType: "messageBoxType" }, outputs: { sendMessage: "sendMessage", executeAction: "executeAction" }, host: { properties: { "class": "this.className", "attr.dir": "this.dirAttr" } }, providers: [
|
|
117
117
|
LocalizationService,
|
|
118
118
|
{
|
|
119
119
|
provide: L10N_PREFIX,
|
|
@@ -127,27 +127,35 @@ ChatComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version:
|
|
|
127
127
|
|
|
128
128
|
i18n-send="kendo.chat.send|The text for the Send button"
|
|
129
129
|
send="Send..."
|
|
130
|
+
|
|
131
|
+
i18n-messageListLabel="kendo.chat.messageListLabel|The label text for the Message list"
|
|
132
|
+
messageListLabel="Message list"
|
|
133
|
+
|
|
134
|
+
i18n-messageBoxInputLabel="kendo.chat.messageBoxInputLabel|The label text for the Message input box"
|
|
135
|
+
messageBoxInputLabel="Message"
|
|
130
136
|
>
|
|
131
137
|
</ng-container>
|
|
132
138
|
|
|
133
139
|
<div
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
140
|
+
#messageList
|
|
141
|
+
class="k-message-list k-avatars"
|
|
142
|
+
aria-live="polite"
|
|
143
|
+
role="log"
|
|
144
|
+
kendoChatScrollAnchor
|
|
145
|
+
[attr.aria-label]="textFor('messageListLabel')"
|
|
138
146
|
#anchor="scrollAnchor"
|
|
139
147
|
[(autoScroll)]="autoScroll"
|
|
140
148
|
>
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
149
|
+
<kendo-chat-message-list
|
|
150
|
+
[messages]="messages"
|
|
151
|
+
[messageTemplate]="messageTemplate"
|
|
152
|
+
[attachmentTemplate]="attachmentTemplate"
|
|
153
|
+
[user]="user"
|
|
154
|
+
(executeAction)="dispatchAction($event)"
|
|
155
|
+
(resize)="anchor.scrollToBottom()"
|
|
156
|
+
(navigate)="this.autoScroll = false"
|
|
157
|
+
>
|
|
158
|
+
</kendo-chat-message-list>
|
|
151
159
|
</div>
|
|
152
160
|
<kendo-message-box
|
|
153
161
|
#messageBox
|
|
@@ -160,7 +168,7 @@ ChatComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version:
|
|
|
160
168
|
>
|
|
161
169
|
</kendo-message-box>
|
|
162
170
|
`, isInline: true, components: [{ type: i2.MessageListComponent, selector: "kendo-chat-message-list", inputs: ["messages", "attachmentTemplate", "messageTemplate", "user"], outputs: ["executeAction", "navigate", "resize"] }, { type: i3.MessageBoxComponent, selector: "kendo-message-box", inputs: ["user", "autoScroll", "type", "localization", "messageBoxTemplate"], outputs: ["sendMessage"] }], directives: [{ type: i4.LocalizedMessagesDirective, selector: "[kendoChatLocalizedMessages]" }, { type: i5.ScrollAnchorDirective, selector: "[kendoChatScrollAnchor]", inputs: ["autoScroll"], outputs: ["autoScrollChange"], exportAs: ["scrollAnchor"] }] });
|
|
163
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.
|
|
171
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.12", ngImport: i0, type: ChatComponent, decorators: [{
|
|
164
172
|
type: Component,
|
|
165
173
|
args: [{
|
|
166
174
|
providers: [
|
|
@@ -179,27 +187,35 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.11", ngImpo
|
|
|
179
187
|
|
|
180
188
|
i18n-send="kendo.chat.send|The text for the Send button"
|
|
181
189
|
send="Send..."
|
|
190
|
+
|
|
191
|
+
i18n-messageListLabel="kendo.chat.messageListLabel|The label text for the Message list"
|
|
192
|
+
messageListLabel="Message list"
|
|
193
|
+
|
|
194
|
+
i18n-messageBoxInputLabel="kendo.chat.messageBoxInputLabel|The label text for the Message input box"
|
|
195
|
+
messageBoxInputLabel="Message"
|
|
182
196
|
>
|
|
183
197
|
</ng-container>
|
|
184
198
|
|
|
185
199
|
<div
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
|
|
200
|
+
#messageList
|
|
201
|
+
class="k-message-list k-avatars"
|
|
202
|
+
aria-live="polite"
|
|
203
|
+
role="log"
|
|
204
|
+
kendoChatScrollAnchor
|
|
205
|
+
[attr.aria-label]="textFor('messageListLabel')"
|
|
190
206
|
#anchor="scrollAnchor"
|
|
191
207
|
[(autoScroll)]="autoScroll"
|
|
192
208
|
>
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
|
|
209
|
+
<kendo-chat-message-list
|
|
210
|
+
[messages]="messages"
|
|
211
|
+
[messageTemplate]="messageTemplate"
|
|
212
|
+
[attachmentTemplate]="attachmentTemplate"
|
|
213
|
+
[user]="user"
|
|
214
|
+
(executeAction)="dispatchAction($event)"
|
|
215
|
+
(resize)="anchor.scrollToBottom()"
|
|
216
|
+
(navigate)="this.autoScroll = false"
|
|
217
|
+
>
|
|
218
|
+
</kendo-chat-message-list>
|
|
203
219
|
</div>
|
|
204
220
|
<kendo-message-box
|
|
205
221
|
#messageBox
|
|
@@ -63,8 +63,8 @@ const PRIVATE_DIRECTIVES = [
|
|
|
63
63
|
*/
|
|
64
64
|
export class ChatModule {
|
|
65
65
|
}
|
|
66
|
-
ChatModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.
|
|
67
|
-
ChatModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "13.3.
|
|
66
|
+
ChatModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.12", ngImport: i0, type: ChatModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
|
|
67
|
+
ChatModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "13.3.12", ngImport: i0, type: ChatModule, declarations: [ChatComponent,
|
|
68
68
|
CustomMessagesComponent,
|
|
69
69
|
AttachmentTemplateDirective,
|
|
70
70
|
MessageTemplateDirective,
|
|
@@ -86,12 +86,12 @@ ChatModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "13
|
|
|
86
86
|
MessageTemplateDirective,
|
|
87
87
|
HeroCardComponent,
|
|
88
88
|
ChatMessageBoxTemplateDirective] });
|
|
89
|
-
ChatModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "13.3.
|
|
89
|
+
ChatModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "13.3.12", ngImport: i0, type: ChatModule, imports: [[
|
|
90
90
|
ButtonModule,
|
|
91
91
|
CommonModule,
|
|
92
92
|
ResizeSensorModule
|
|
93
93
|
]] });
|
|
94
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.
|
|
94
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.12", ngImport: i0, type: ChatModule, decorators: [{
|
|
95
95
|
type: NgModule,
|
|
96
96
|
args: [{
|
|
97
97
|
declarations: [
|
|
@@ -21,14 +21,14 @@ export class CustomMessagesComponent extends Messages {
|
|
|
21
21
|
return true;
|
|
22
22
|
}
|
|
23
23
|
}
|
|
24
|
-
CustomMessagesComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.
|
|
25
|
-
CustomMessagesComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.3.
|
|
24
|
+
CustomMessagesComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.12", ngImport: i0, type: CustomMessagesComponent, deps: [{ token: i1.LocalizationService }], target: i0.ɵɵFactoryTarget.Component });
|
|
25
|
+
CustomMessagesComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.3.12", type: CustomMessagesComponent, selector: "kendo-chat-messages", providers: [
|
|
26
26
|
{
|
|
27
27
|
provide: Messages,
|
|
28
28
|
useExisting: forwardRef(() => CustomMessagesComponent)
|
|
29
29
|
}
|
|
30
30
|
], usesInheritance: true, ngImport: i0, template: ``, isInline: true });
|
|
31
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.
|
|
31
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.12", ngImport: i0, type: CustomMessagesComponent, decorators: [{
|
|
32
32
|
type: Component,
|
|
33
33
|
args: [{
|
|
34
34
|
providers: [
|
|
@@ -17,14 +17,14 @@ export class LocalizedMessagesDirective extends Messages {
|
|
|
17
17
|
this.service = service;
|
|
18
18
|
}
|
|
19
19
|
}
|
|
20
|
-
LocalizedMessagesDirective.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.
|
|
21
|
-
LocalizedMessagesDirective.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "12.0.0", version: "13.3.
|
|
20
|
+
LocalizedMessagesDirective.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.12", ngImport: i0, type: LocalizedMessagesDirective, deps: [{ token: i1.LocalizationService }], target: i0.ɵɵFactoryTarget.Directive });
|
|
21
|
+
LocalizedMessagesDirective.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "12.0.0", version: "13.3.12", type: LocalizedMessagesDirective, selector: "[kendoChatLocalizedMessages]", providers: [
|
|
22
22
|
{
|
|
23
23
|
provide: Messages,
|
|
24
24
|
useExisting: forwardRef(() => LocalizedMessagesDirective)
|
|
25
25
|
}
|
|
26
26
|
], usesInheritance: true, ngImport: i0 });
|
|
27
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.
|
|
27
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.12", ngImport: i0, type: LocalizedMessagesDirective, decorators: [{
|
|
28
28
|
type: Directive,
|
|
29
29
|
args: [{
|
|
30
30
|
providers: [
|
|
@@ -10,9 +10,9 @@ import * as i0 from "@angular/core";
|
|
|
10
10
|
*/
|
|
11
11
|
export class Messages extends ComponentMessages {
|
|
12
12
|
}
|
|
13
|
-
Messages.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.
|
|
14
|
-
Messages.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "12.0.0", version: "13.3.
|
|
15
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.
|
|
13
|
+
Messages.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.12", ngImport: i0, type: Messages, deps: null, target: i0.ɵɵFactoryTarget.Directive });
|
|
14
|
+
Messages.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "12.0.0", version: "13.3.12", type: Messages, selector: "kendoConversationalUIMessages", inputs: { messagePlaceholder: "messagePlaceholder", send: "send", messageListLabel: "messageListLabel", messageBoxInputLabel: "messageBoxInputLabel" }, usesInheritance: true, ngImport: i0 });
|
|
15
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.12", ngImport: i0, type: Messages, decorators: [{
|
|
16
16
|
type: Directive,
|
|
17
17
|
args: [{
|
|
18
18
|
// eslint-disable-next-line @angular-eslint/directive-selector
|
|
@@ -22,4 +22,8 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.11", ngImpo
|
|
|
22
22
|
type: Input
|
|
23
23
|
}], send: [{
|
|
24
24
|
type: Input
|
|
25
|
+
}], messageListLabel: [{
|
|
26
|
+
type: Input
|
|
27
|
+
}], messageBoxInputLabel: [{
|
|
28
|
+
type: Input
|
|
25
29
|
}] } });
|
|
@@ -5,6 +5,7 @@
|
|
|
5
5
|
import { Component, ElementRef, forwardRef, HostBinding, Input, NgZone, QueryList, ViewChild, ViewChildren } from '@angular/core';
|
|
6
6
|
import { fromEvent } from 'rxjs';
|
|
7
7
|
import { debounceTime } from 'rxjs/operators';
|
|
8
|
+
import { Keys } from '@progress/kendo-angular-common';
|
|
8
9
|
import { ChatItem } from './chat-item';
|
|
9
10
|
import { AttachmentTemplateDirective } from './attachment-template.directive';
|
|
10
11
|
import { chevronLeftIcon, chevronRightIcon } from '@progress/kendo-svg-icons';
|
|
@@ -31,12 +32,12 @@ export class MessageAttachmentsComponent extends ChatItem {
|
|
|
31
32
|
this.scrollPosition = 0;
|
|
32
33
|
this.selectedIndex = 0;
|
|
33
34
|
this.carouselKeyHandlers = {
|
|
34
|
-
[
|
|
35
|
-
[
|
|
35
|
+
[Keys.ArrowLeft]: (e) => this.navigateTo(e, -1),
|
|
36
|
+
[Keys.ArrowRight]: (e) => this.navigateTo(e, 1)
|
|
36
37
|
};
|
|
37
38
|
this.listKeyHandlers = {
|
|
38
|
-
[
|
|
39
|
-
[
|
|
39
|
+
[Keys.ArrowUp]: (e) => this.navigateTo(e, -1),
|
|
40
|
+
[Keys.ArrowDown]: (e) => this.navigateTo(e, 1)
|
|
40
41
|
};
|
|
41
42
|
}
|
|
42
43
|
get carousel() {
|
|
@@ -105,8 +106,8 @@ export class MessageAttachmentsComponent extends ChatItem {
|
|
|
105
106
|
}
|
|
106
107
|
}
|
|
107
108
|
}
|
|
108
|
-
MessageAttachmentsComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.
|
|
109
|
-
MessageAttachmentsComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.3.
|
|
109
|
+
MessageAttachmentsComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.12", ngImport: i0, type: MessageAttachmentsComponent, deps: [{ token: i0.NgZone }], target: i0.ɵɵFactoryTarget.Component });
|
|
110
|
+
MessageAttachmentsComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.3.12", type: MessageAttachmentsComponent, selector: "kendo-chat-message-attachments", inputs: { attachments: "attachments", layout: "layout", tabbable: "tabbable", template: "template" }, host: { properties: { "class.k-card-deck-scrollwrap": "this.carousel" } }, providers: [{
|
|
110
111
|
provide: ChatItem,
|
|
111
112
|
useExisting: forwardRef(() => MessageAttachmentsComponent)
|
|
112
113
|
}], viewQueries: [{ propertyName: "deck", first: true, predicate: ["deck"], descendants: true, read: ElementRef, static: true }, { propertyName: "items", predicate: ["item"], descendants: true, read: ElementRef }], usesInheritance: true, ngImport: i0, template: `
|
|
@@ -145,7 +146,7 @@ MessageAttachmentsComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.
|
|
|
145
146
|
>
|
|
146
147
|
</button>
|
|
147
148
|
`, isInline: true, components: [{ type: i1.Button, selector: "button[kendoButton], span[kendoButton], kendo-button", inputs: ["toggleable", "togglable", "selected", "tabIndex", "imageUrl", "iconClass", "icon", "disabled", "size", "rounded", "fillMode", "themeColor", "svgIcon", "role", "primary", "look"], outputs: ["selectedChange", "click"], exportAs: ["kendoButton"] }, { type: i2.AttachmentComponent, selector: "kendo-chat-attachment", inputs: ["attachment", "template"] }], directives: [{ type: i3.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i3.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }] });
|
|
148
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.
|
|
149
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.12", ngImport: i0, type: MessageAttachmentsComponent, decorators: [{
|
|
149
150
|
type: Component,
|
|
150
151
|
args: [{
|
|
151
152
|
providers: [{
|
|
@@ -76,9 +76,9 @@ export class MessageBoxComponent {
|
|
|
76
76
|
return this.localization.get(key);
|
|
77
77
|
}
|
|
78
78
|
}
|
|
79
|
-
MessageBoxComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.
|
|
80
|
-
MessageBoxComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.3.
|
|
81
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.
|
|
79
|
+
MessageBoxComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.12", ngImport: i0, type: MessageBoxComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
80
|
+
MessageBoxComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.3.12", type: MessageBoxComponent, selector: "kendo-message-box", inputs: { user: "user", autoScroll: "autoScroll", type: "type", localization: "localization", messageBoxTemplate: "messageBoxTemplate" }, outputs: { sendMessage: "sendMessage" }, host: { properties: { "class": "this.hostClasses", "class.!k-align-items-end": "this.messageBoxValue" } }, viewQueries: [{ propertyName: "messageBoxInput", first: true, predicate: ["messageBoxInput"], descendants: true }], ngImport: i0, template: "\n <ng-container *ngIf=\"!messageBoxTemplate\">\n <input\n *ngIf=\"type === 'textbox'\"\n #messageBoxInput\n [attr.role]=\"'textbox'\"\n kendoChatFocusedState\n type=\"text\"\n class=\"k-textbox k-input k-input-md k-input-solid\"\n [attr.aria-label]=\"textFor('messageBoxInputLabel')\"\n [placeholder]=\"textFor('messagePlaceholder')\"\n (keydown)=\"inputKeydown($event)\"\n />\n\n <textarea\n *ngIf=\"type === 'textarea'\"\n #messageBoxInput\n [attr.role]=\"'textbox'\"\n kendoChatFocusedState\n [rows]=\"3\"\n class=\"k-textarea k-input k-input-md k-input-solid !k-overflow-y-auto k-resize-none\"\n [attr.aria-label]=\"textFor('messageBoxInputLabel')\"\n [placeholder]=\"textFor('messagePlaceholder')\"\n (keydown)=\"textAreaKeydown($event)\"\n ></textarea>\n\n <button\n kendoButton\n fillMode=\"flat\"\n class=\"k-button-send\"\n [tabindex]=\"0\"\n [attr.title]=\"textFor('send')\"\n (click)=\"sendClick()\"\n >\n <svg version=\"1.1\" xmlns=\"http://www.w3.org/2000/svg\" x=\"0px\" y=\"0px\" viewBox=\"0 0 16 16\"><path d=\"M0,14.3c-0.1,0.6,0.3,0.8,0.8,0.6l14.8-6.5c0.5-0.2,0.5-0.6,0-0.8L0.8,1.1C0.3,0.9-0.1,1.1,0,1.7l0.7,4.2C0.8,6.5,1.4,7,1.9,7.1l8.8,0.8c0.6,0.1,0.6,0.1,0,0.2L1.9,8.9C1.4,9,0.8,9.5,0.7,10.1L0,14.3z\"/></svg>\n </button>\n </ng-container>\n\n <ng-template *ngIf=\"messageBoxTemplate\" [ngTemplateOutlet]=\"messageBoxTemplate?.templateRef\"></ng-template>\n", isInline: true, components: [{ type: i1.Button, selector: "button[kendoButton], span[kendoButton], kendo-button", inputs: ["toggleable", "togglable", "selected", "tabIndex", "imageUrl", "iconClass", "icon", "disabled", "size", "rounded", "fillMode", "themeColor", "svgIcon", "role", "primary", "look"], outputs: ["selectedChange", "click"], exportAs: ["kendoButton"] }], directives: [{ type: i2.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i3.FocusedStateDirective, selector: "[kendoChatFocusedState]" }, { type: i2.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet"] }] });
|
|
81
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.12", ngImport: i0, type: MessageBoxComponent, decorators: [{
|
|
82
82
|
type: Component,
|
|
83
83
|
args: [{
|
|
84
84
|
selector: 'kendo-message-box',
|
|
@@ -87,21 +87,25 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.11", ngImpo
|
|
|
87
87
|
<input
|
|
88
88
|
*ngIf="type === 'textbox'"
|
|
89
89
|
#messageBoxInput
|
|
90
|
+
[attr.role]="'textbox'"
|
|
90
91
|
kendoChatFocusedState
|
|
91
92
|
type="text"
|
|
92
93
|
class="k-textbox k-input k-input-md k-input-solid"
|
|
94
|
+
[attr.aria-label]="textFor('messageBoxInputLabel')"
|
|
93
95
|
[placeholder]="textFor('messagePlaceholder')"
|
|
94
96
|
(keydown)="inputKeydown($event)"
|
|
95
97
|
/>
|
|
96
98
|
|
|
97
99
|
<textarea
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
100
|
+
*ngIf="type === 'textarea'"
|
|
101
|
+
#messageBoxInput
|
|
102
|
+
[attr.role]="'textbox'"
|
|
103
|
+
kendoChatFocusedState
|
|
104
|
+
[rows]="3"
|
|
105
|
+
class="k-textarea k-input k-input-md k-input-solid !k-overflow-y-auto k-resize-none"
|
|
106
|
+
[attr.aria-label]="textFor('messageBoxInputLabel')"
|
|
107
|
+
[placeholder]="textFor('messagePlaceholder')"
|
|
108
|
+
(keydown)="textAreaKeydown($event)"
|
|
105
109
|
></textarea>
|
|
106
110
|
|
|
107
111
|
<button
|
|
@@ -14,9 +14,9 @@ export class ChatMessageBoxTemplateDirective {
|
|
|
14
14
|
this.templateRef = templateRef;
|
|
15
15
|
}
|
|
16
16
|
}
|
|
17
|
-
ChatMessageBoxTemplateDirective.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.
|
|
18
|
-
ChatMessageBoxTemplateDirective.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "12.0.0", version: "13.3.
|
|
19
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.
|
|
17
|
+
ChatMessageBoxTemplateDirective.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.12", ngImport: i0, type: ChatMessageBoxTemplateDirective, deps: [{ token: i0.TemplateRef }], target: i0.ɵɵFactoryTarget.Directive });
|
|
18
|
+
ChatMessageBoxTemplateDirective.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "12.0.0", version: "13.3.12", type: ChatMessageBoxTemplateDirective, selector: "[kendoChatMessageBoxTemplate]", ngImport: i0 });
|
|
19
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.12", ngImport: i0, type: ChatMessageBoxTemplateDirective, decorators: [{
|
|
20
20
|
type: Directive,
|
|
21
21
|
args: [{
|
|
22
22
|
selector: '[kendoChatMessageBoxTemplate]'
|
|
@@ -2,14 +2,20 @@
|
|
|
2
2
|
* Copyright © 2023 Progress Software Corporation. All rights reserved.
|
|
3
3
|
* Licensed under commercial license. See LICENSE.md in the project root for more information
|
|
4
4
|
*-------------------------------------------------------------------------------------------*/
|
|
5
|
-
|
|
5
|
+
/* eslint-disable @typescript-eslint/no-unused-vars */
|
|
6
|
+
/* eslint-disable @typescript-eslint/no-explicit-any */
|
|
7
|
+
import { Component, ElementRef, EventEmitter, HostBinding, Input, Output, QueryList, Renderer2, ViewChildren } from '@angular/core';
|
|
6
8
|
import { ExecuteActionEvent } from '../api';
|
|
9
|
+
import { Keys } from '@progress/kendo-angular-common';
|
|
7
10
|
import { closest } from '../common/utils';
|
|
8
11
|
import { ChatItem } from './chat-item';
|
|
9
12
|
import { chatView, isAuthor } from './chat-view';
|
|
10
13
|
import { AttachmentTemplateDirective } from './attachment-template.directive';
|
|
11
14
|
import { MessageTemplateDirective } from './message-template.directive';
|
|
12
15
|
import { IntlService } from '@progress/kendo-angular-intl';
|
|
16
|
+
import { Subscription } from 'rxjs';
|
|
17
|
+
import { SuggestedActionsComponent } from './suggested-actions.component';
|
|
18
|
+
import { MessageComponent } from './message.component';
|
|
13
19
|
import * as i0 from "@angular/core";
|
|
14
20
|
import * as i1 from "@progress/kendo-angular-intl";
|
|
15
21
|
import * as i2 from "./message.component";
|
|
@@ -22,17 +28,22 @@ import * as i7 from "@angular/common";
|
|
|
22
28
|
* @hidden
|
|
23
29
|
*/
|
|
24
30
|
export class MessageListComponent {
|
|
25
|
-
constructor(element, intl) {
|
|
31
|
+
constructor(element, intl, renderer) {
|
|
26
32
|
this.element = element;
|
|
27
33
|
this.intl = intl;
|
|
34
|
+
this.renderer = renderer;
|
|
28
35
|
this.executeAction = new EventEmitter();
|
|
29
36
|
this.navigate = new EventEmitter();
|
|
30
37
|
this.resize = new EventEmitter();
|
|
31
38
|
this.cssClass = true;
|
|
32
39
|
this.view = [];
|
|
40
|
+
this.subs = new Subscription();
|
|
33
41
|
this.keyActions = {
|
|
34
|
-
[
|
|
35
|
-
[
|
|
42
|
+
[Keys.Home]: (_) => this.onHomeOrEndKeyDown('home'),
|
|
43
|
+
[Keys.End]: (_) => this.onHomeOrEndKeyDown('end'),
|
|
44
|
+
[Keys.ArrowUp]: (e) => this.navigateTo(e, -1),
|
|
45
|
+
[Keys.ArrowDown]: (e) => this.navigateTo(e, 1),
|
|
46
|
+
[Keys.Tab]: (e) => this.onTabKeyDown(e),
|
|
36
47
|
};
|
|
37
48
|
}
|
|
38
49
|
set messages(value) {
|
|
@@ -43,9 +54,17 @@ export class MessageListComponent {
|
|
|
43
54
|
get messages() {
|
|
44
55
|
return this._messages;
|
|
45
56
|
}
|
|
57
|
+
ngOnInit() {
|
|
58
|
+
const elRef = this.element.nativeElement;
|
|
59
|
+
this.subs.add(this.renderer.listen(elRef, 'keydown', event => this.onKeydown(event)));
|
|
60
|
+
this.subs.add(this.renderer.listen(elRef, 'focusout', event => this.onBlur(event)));
|
|
61
|
+
}
|
|
46
62
|
ngAfterViewInit() {
|
|
47
63
|
this.selectedItem = this.items.last;
|
|
48
64
|
}
|
|
65
|
+
ngOnDestroy() {
|
|
66
|
+
this.subs.unsubscribe();
|
|
67
|
+
}
|
|
49
68
|
onResize() {
|
|
50
69
|
this.resize.emit();
|
|
51
70
|
}
|
|
@@ -91,13 +110,37 @@ export class MessageListComponent {
|
|
|
91
110
|
}
|
|
92
111
|
return items[items.length - 1];
|
|
93
112
|
}
|
|
113
|
+
onHomeOrEndKeyDown(key) {
|
|
114
|
+
const items = this.items.toArray();
|
|
115
|
+
if (key === 'home') {
|
|
116
|
+
items[0].focus();
|
|
117
|
+
}
|
|
118
|
+
else {
|
|
119
|
+
items[items.length - 1].focus();
|
|
120
|
+
}
|
|
121
|
+
}
|
|
122
|
+
onTabKeyDown(event) {
|
|
123
|
+
const item = this.items.toArray()[this.items.length - 1];
|
|
124
|
+
const isLastItemQuickReply = item instanceof SuggestedActionsComponent;
|
|
125
|
+
const isLastItemMessage = item instanceof MessageComponent;
|
|
126
|
+
event.target.blur();
|
|
127
|
+
if (isLastItemQuickReply || isLastItemMessage) {
|
|
128
|
+
this.select(item);
|
|
129
|
+
item.focus();
|
|
130
|
+
this.navigate.emit();
|
|
131
|
+
}
|
|
132
|
+
}
|
|
94
133
|
navigateTo(e, offset) {
|
|
95
134
|
const items = this.items.toArray();
|
|
96
135
|
const prevItem = this.selectedItem;
|
|
97
136
|
const prevIndex = items.indexOf(prevItem);
|
|
98
137
|
const nextIndex = Math.max(0, Math.min(prevIndex + offset, this.items.length - 1));
|
|
99
138
|
const nextItem = items[nextIndex];
|
|
139
|
+
const isNextItemQuickReply = nextItem instanceof SuggestedActionsComponent;
|
|
100
140
|
if (nextItem !== prevItem) {
|
|
141
|
+
if (isNextItemQuickReply) {
|
|
142
|
+
nextItem.items.toArray()[0].nativeElement.focus();
|
|
143
|
+
}
|
|
101
144
|
this.select(nextItem);
|
|
102
145
|
nextItem.focus();
|
|
103
146
|
this.navigate.emit();
|
|
@@ -105,8 +148,8 @@ export class MessageListComponent {
|
|
|
105
148
|
}
|
|
106
149
|
}
|
|
107
150
|
}
|
|
108
|
-
MessageListComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.
|
|
109
|
-
MessageListComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.3.
|
|
151
|
+
MessageListComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.12", ngImport: i0, type: MessageListComponent, deps: [{ token: i0.ElementRef }, { token: i1.IntlService }, { token: i0.Renderer2 }], target: i0.ɵɵFactoryTarget.Component });
|
|
152
|
+
MessageListComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.3.12", type: MessageListComponent, selector: "kendo-chat-message-list", inputs: { messages: "messages", attachmentTemplate: "attachmentTemplate", messageTemplate: "messageTemplate", user: "user" }, outputs: { executeAction: "executeAction", navigate: "navigate", resize: "resize" }, host: { properties: { "class.k-message-list-content": "this.cssClass" } }, viewQueries: [{ propertyName: "items", predicate: ChatItem, descendants: true }], ngImport: i0, template: `
|
|
110
153
|
<ng-container *ngFor="let group of view; last as lastGroup; trackBy: trackGroup">
|
|
111
154
|
<ng-container [ngSwitch]="group.type">
|
|
112
155
|
<div
|
|
@@ -177,7 +220,7 @@ MessageListComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", v
|
|
|
177
220
|
<kendo-resize-sensor (resize)="onResize()">
|
|
178
221
|
</kendo-resize-sensor>
|
|
179
222
|
`, isInline: true, components: [{ type: i2.MessageComponent, selector: "kendo-chat-message", inputs: ["message", "tabbable", "template"] }, { type: i3.AttachmentComponent, selector: "kendo-chat-attachment", inputs: ["attachment", "template"] }, { type: i4.MessageAttachmentsComponent, selector: "kendo-chat-message-attachments", inputs: ["attachments", "layout", "tabbable", "template"] }, { type: i5.SuggestedActionsComponent, selector: "kendo-chat-suggested-actions", inputs: ["actions", "tabbable"], outputs: ["dispatch"] }, { type: i6.ResizeSensorComponent, selector: "kendo-resize-sensor", inputs: ["rateLimit"], outputs: ["resize"] }], directives: [{ type: i7.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { type: i7.NgSwitch, selector: "[ngSwitch]", inputs: ["ngSwitch"] }, { type: i7.NgSwitchCase, selector: "[ngSwitchCase]", inputs: ["ngSwitchCase"] }, { type: i7.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }] });
|
|
180
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.
|
|
223
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.12", ngImport: i0, type: MessageListComponent, decorators: [{
|
|
181
224
|
type: Component,
|
|
182
225
|
args: [{
|
|
183
226
|
selector: 'kendo-chat-message-list',
|
|
@@ -253,7 +296,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.11", ngImpo
|
|
|
253
296
|
</kendo-resize-sensor>
|
|
254
297
|
`
|
|
255
298
|
}]
|
|
256
|
-
}], ctorParameters: function () { return [{ type: i0.ElementRef }, { type: i1.IntlService }]; }, propDecorators: { messages: [{
|
|
299
|
+
}], ctorParameters: function () { return [{ type: i0.ElementRef }, { type: i1.IntlService }, { type: i0.Renderer2 }]; }, propDecorators: { messages: [{
|
|
257
300
|
type: Input
|
|
258
301
|
}], attachmentTemplate: [{
|
|
259
302
|
type: Input
|
|
@@ -273,10 +316,4 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.11", ngImpo
|
|
|
273
316
|
}], cssClass: [{
|
|
274
317
|
type: HostBinding,
|
|
275
318
|
args: ['class.k-message-list-content']
|
|
276
|
-
}], onKeydown: [{
|
|
277
|
-
type: HostListener,
|
|
278
|
-
args: ['keydown', ['$event']]
|
|
279
|
-
}], onBlur: [{
|
|
280
|
-
type: HostListener,
|
|
281
|
-
args: ['focusout', ['$event']]
|
|
282
319
|
}] } });
|