@progress/kendo-angular-conversational-ui 14.4.0-develop.9 → 15.0.0-develop.2

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.
Files changed (103) hide show
  1. package/NOTICE.txt +146 -593
  2. package/ai-prompt/aiprompt.component.d.ts +120 -0
  3. package/ai-prompt/aiprompt.module.d.ts +25 -0
  4. package/ai-prompt/common/aiprompt.service.d.ts +26 -0
  5. package/ai-prompt/common/output-card.component.d.ts +36 -0
  6. package/ai-prompt/common/toolbar-focusable.directive.d.ts +24 -0
  7. package/ai-prompt/common/toolbar-navigation.service.d.ts +24 -0
  8. package/ai-prompt/localization/custom-messages.component.d.ts +17 -0
  9. package/ai-prompt/localization/localized-messages.directive.d.ts +16 -0
  10. package/ai-prompt/localization/messages.d.ts +49 -0
  11. package/ai-prompt/models/command-execute-event.d.ts +23 -0
  12. package/ai-prompt/models/command.interface.d.ts +30 -0
  13. package/ai-prompt/models/index.d.ts +10 -0
  14. package/ai-prompt/models/output-rating-change-event.d.ts +18 -0
  15. package/ai-prompt/models/prompt-output.interface.d.ts +41 -0
  16. package/ai-prompt/models/prompt-request-event.d.ts +22 -0
  17. package/ai-prompt/models/view-type.d.ts +8 -0
  18. package/ai-prompt/templates/toolbar-actions.template.d.ts +18 -0
  19. package/ai-prompt/utils.d.ts +19 -0
  20. package/ai-prompt/views/base-view.d.ts +46 -0
  21. package/ai-prompt/views/command-view.component.d.ts +23 -0
  22. package/ai-prompt/views/custom-view.component.d.ts +20 -0
  23. package/ai-prompt/views/index.d.ts +8 -0
  24. package/ai-prompt/views/output-view.component.d.ts +22 -0
  25. package/ai-prompt/views/prompt-view.component.d.ts +47 -0
  26. package/{api → chat/api}/execute-action-event.d.ts +2 -1
  27. package/chat/attachment-template.directive.d.ts +1 -1
  28. package/chat/attachment.component.d.ts +1 -1
  29. package/chat/builtin-actions.d.ts +1 -1
  30. package/chat/chat-view.d.ts +1 -1
  31. package/chat/chat.component.d.ts +3 -3
  32. package/chat/chat.module.d.ts +3 -3
  33. package/chat/message-attachments.component.d.ts +1 -1
  34. package/chat/message-box.component.d.ts +2 -2
  35. package/chat/message-list.component.d.ts +1 -1
  36. package/chat/message-template.directive.d.ts +1 -1
  37. package/chat/message.component.d.ts +1 -1
  38. package/chat/suggested-actions.component.d.ts +1 -1
  39. package/conversational-ui.module.d.ts +43 -0
  40. package/esm2020/ai-prompt/aiprompt.component.mjs +348 -0
  41. package/esm2020/ai-prompt/aiprompt.module.mjs +79 -0
  42. package/esm2020/ai-prompt/common/aiprompt.service.mjs +38 -0
  43. package/esm2020/ai-prompt/common/output-card.component.mjs +199 -0
  44. package/esm2020/ai-prompt/common/toolbar-focusable.directive.mjs +67 -0
  45. package/esm2020/ai-prompt/common/toolbar-navigation.service.mjs +55 -0
  46. package/esm2020/ai-prompt/localization/custom-messages.component.mjs +41 -0
  47. package/esm2020/ai-prompt/localization/localized-messages.directive.mjs +37 -0
  48. package/esm2020/ai-prompt/localization/messages.mjs +35 -0
  49. package/esm2020/ai-prompt/models/prompt-output.interface.mjs +5 -0
  50. package/esm2020/ai-prompt/models/prompt-request-event.mjs +5 -0
  51. package/esm2020/ai-prompt/models/view-type.mjs +5 -0
  52. package/esm2020/ai-prompt/templates/toolbar-actions.template.mjs +27 -0
  53. package/esm2020/ai-prompt/utils.mjs +26 -0
  54. package/esm2020/ai-prompt/views/base-view.mjs +89 -0
  55. package/esm2020/ai-prompt/views/command-view.component.mjs +82 -0
  56. package/esm2020/ai-prompt/views/custom-view.component.mjs +35 -0
  57. package/esm2020/ai-prompt/views/index.mjs +8 -0
  58. package/esm2020/ai-prompt/views/output-view.component.mjs +66 -0
  59. package/esm2020/ai-prompt/views/prompt-view.component.mjs +146 -0
  60. package/esm2020/chat/api/attachment.interface.mjs +5 -0
  61. package/esm2020/chat/api/message.interface.mjs +5 -0
  62. package/esm2020/chat/api/user.interface.mjs +5 -0
  63. package/esm2020/chat/attachment-template.directive.mjs +1 -1
  64. package/esm2020/chat/builtin-actions.mjs +1 -1
  65. package/esm2020/chat/chat.component.mjs +2 -2
  66. package/esm2020/chat/chat.module.mjs +3 -3
  67. package/esm2020/chat/common/models/message-box-options.mjs +5 -0
  68. package/esm2020/chat/message-box.component.mjs +2 -2
  69. package/esm2020/chat/message-list.component.mjs +2 -2
  70. package/esm2020/chat/message-template.directive.mjs +1 -1
  71. package/esm2020/conversational-ui.module.mjs +50 -0
  72. package/esm2020/index.mjs +10 -2
  73. package/esm2020/package-metadata.mjs +2 -2
  74. package/fesm2015/progress-kendo-angular-conversational-ui.mjs +1414 -152
  75. package/fesm2020/progress-kendo-angular-conversational-ui.mjs +1302 -46
  76. package/index.d.ts +11 -3
  77. package/package.json +10 -7
  78. package/schematics/ngAdd/index.js +4 -2
  79. /package/{api → chat/api}/action.interface.d.ts +0 -0
  80. /package/{api → chat/api}/attachment.interface.d.ts +0 -0
  81. /package/{api → chat/api}/index.d.ts +0 -0
  82. /package/{api → chat/api}/message.interface.d.ts +0 -0
  83. /package/{api → chat/api}/post-message-event.d.ts +0 -0
  84. /package/{api → chat/api}/preventable-event.d.ts +0 -0
  85. /package/{api → chat/api}/user.interface.d.ts +0 -0
  86. /package/{cards → chat/cards}/hero-card.component.d.ts +0 -0
  87. /package/{common → chat/common}/focused-state.directive.d.ts +0 -0
  88. /package/{common → chat/common}/models/message-box-options.d.ts +0 -0
  89. /package/{common → chat/common}/scroll-anchor.directive.d.ts +0 -0
  90. /package/{common → chat/common}/utils.d.ts +0 -0
  91. /package/esm2020/{api/attachment.interface.mjs → ai-prompt/models/command-execute-event.mjs} +0 -0
  92. /package/esm2020/{api/message.interface.mjs → ai-prompt/models/command.interface.mjs} +0 -0
  93. /package/esm2020/{api/user.interface.mjs → ai-prompt/models/index.mjs} +0 -0
  94. /package/esm2020/{common/models/message-box-options.mjs → ai-prompt/models/output-rating-change-event.mjs} +0 -0
  95. /package/esm2020/{api → chat/api}/action.interface.mjs +0 -0
  96. /package/esm2020/{api → chat/api}/execute-action-event.mjs +0 -0
  97. /package/esm2020/{api → chat/api}/index.mjs +0 -0
  98. /package/esm2020/{api → chat/api}/post-message-event.mjs +0 -0
  99. /package/esm2020/{api → chat/api}/preventable-event.mjs +0 -0
  100. /package/esm2020/{cards → chat/cards}/hero-card.component.mjs +0 -0
  101. /package/esm2020/{common → chat/common}/focused-state.directive.mjs +0 -0
  102. /package/esm2020/{common → chat/common}/scroll-anchor.directive.mjs +0 -0
  103. /package/esm2020/{common → chat/common}/utils.mjs +0 -0
@@ -0,0 +1,120 @@
1
+ /**-----------------------------------------------------------------------------------------
2
+ * Copyright © 2024 Progress Software Corporation. All rights reserved.
3
+ * Licensed under commercial license. See LICENSE.md in the project root for more information
4
+ *-------------------------------------------------------------------------------------------*/
5
+ import { AfterViewInit, EventEmitter, NgZone, OnDestroy, QueryList, TemplateRef } from "@angular/core";
6
+ import { SVGIcon } from "@progress/kendo-svg-icons";
7
+ import { LocalizationService } from '@progress/kendo-angular-l10n';
8
+ import { BaseView } from "./views/base-view";
9
+ import { AIPromptService } from "./common/aiprompt.service";
10
+ import { PromptCommand, PromptOutput, CommandExecuteEvent, PromptRequestEvent, OutputRatingChangeEvent } from "./models";
11
+ import { AIPromptToolbarActionsDirective } from "./templates/toolbar-actions.template";
12
+ import { ToolbarNavigationService } from "./common/toolbar-navigation.service";
13
+ import * as i0 from "@angular/core";
14
+ /**
15
+ * Represents the Kendo UI AIPrompt component for Angular
16
+ */
17
+ export declare class AIPromptComponent implements AfterViewInit, OnDestroy {
18
+ private localization;
19
+ private service;
20
+ private navigationService;
21
+ private ngZone;
22
+ hostClasses: boolean;
23
+ get dirAttr(): string;
24
+ constructor(localization: LocalizationService, service: AIPromptService, navigationService: ToolbarNavigationService, ngZone: NgZone);
25
+ /**
26
+ * @hidden
27
+ */
28
+ views: QueryList<BaseView>;
29
+ /**
30
+ * @hidden
31
+ */
32
+ toolbarActionsTemplate: AIPromptToolbarActionsDirective;
33
+ /**
34
+ * The active view index of the AIPrompt component.
35
+ */
36
+ activeView: number;
37
+ /**
38
+ * The collection of commands that will be rendered in the Command view.
39
+ */
40
+ set promptCommands(value: Array<PromptCommand>);
41
+ /**
42
+ * The collection of suggestions that will be rendered in the Prompt view.
43
+ */
44
+ set promptSuggestions(value: Array<string>);
45
+ /**
46
+ * The collection of generated prompt outputs that will be rendered in the Output view.
47
+ */
48
+ set promptOutputs(value: Array<PromptOutput>);
49
+ /**
50
+ * Specifies if the rating buttons in each Output view card will be rendered.
51
+ * By default, rating buttons are not rendered.
52
+ *
53
+ * @default false
54
+ */
55
+ set showOutputRating(value: boolean);
56
+ /**
57
+ * Fires when the `activeView` property of the component is updated.
58
+ * Used to provide a two-way binding for the `activeView` property.
59
+ */
60
+ activeViewChange: EventEmitter<number>;
61
+ /**
62
+ * Fires each time the user clicks the Prompt view Generate button or the Output view Retry button.
63
+ * To distinguish the source element, use the event's `isRetry` field.
64
+ */
65
+ promptRequest: EventEmitter<PromptRequestEvent>;
66
+ /**
67
+ * Fires each time the user clicks a Command view command. Exposes the selected command as event data.
68
+ */
69
+ commandExecute: EventEmitter<CommandExecuteEvent>;
70
+ /**
71
+ * Fires each time the user clicks any Output view Copy button.
72
+ */
73
+ outputCopy: EventEmitter<PromptOutput>;
74
+ /**
75
+ * Fires each time the user clicks a rating button in any Output view card.
76
+ */
77
+ outputRatingChange: EventEmitter<OutputRatingChangeEvent>;
78
+ ngAfterViewInit(): void;
79
+ ngOnDestroy(): void;
80
+ /**
81
+ * Focuses the first focusable element in the AI Prompt.
82
+ */
83
+ focus(): void;
84
+ private subs;
85
+ /**
86
+ * @hidden
87
+ */
88
+ get selectedView(): BaseView;
89
+ /**
90
+ * @hidden
91
+ */
92
+ sparklesIcon: SVGIcon;
93
+ /**
94
+ * @hidden
95
+ */
96
+ outputIcon: SVGIcon;
97
+ /**
98
+ * @hidden
99
+ */
100
+ get viewsArray(): Array<BaseView>;
101
+ private direction;
102
+ /**
103
+ * @hidden
104
+ */
105
+ viewChange(idx: number): void;
106
+ /**
107
+ * @hidden
108
+ */
109
+ messageFor(text: string): string;
110
+ /**
111
+ * @hidden
112
+ */
113
+ get viewTemplate(): TemplateRef<any>;
114
+ /**
115
+ * @hidden
116
+ */
117
+ handleGenerateOutput(): void;
118
+ static ɵfac: i0.ɵɵFactoryDeclaration<AIPromptComponent, never>;
119
+ static ɵcmp: i0.ɵɵComponentDeclaration<AIPromptComponent, "kendo-aiprompt", ["kendoAIPrompt"], { "activeView": "activeView"; "promptCommands": "promptCommands"; "promptSuggestions": "promptSuggestions"; "promptOutputs": "promptOutputs"; "showOutputRating": "showOutputRating"; }, { "activeViewChange": "activeViewChange"; "promptRequest": "promptRequest"; "commandExecute": "commandExecute"; "outputCopy": "outputCopy"; "outputRatingChange": "outputRatingChange"; }, ["toolbarActionsTemplate", "views"], never>;
120
+ }
@@ -0,0 +1,25 @@
1
+ /**-----------------------------------------------------------------------------------------
2
+ * Copyright © 2024 Progress Software Corporation. All rights reserved.
3
+ * Licensed under commercial license. See LICENSE.md in the project root for more information
4
+ *-------------------------------------------------------------------------------------------*/
5
+ import * as i0 from "@angular/core";
6
+ import * as i1 from "./aiprompt.component";
7
+ import * as i2 from "./views/prompt-view.component";
8
+ import * as i3 from "./views/output-view.component";
9
+ import * as i4 from "./views/command-view.component";
10
+ import * as i5 from "./views/custom-view.component";
11
+ import * as i6 from "./localization/custom-messages.component";
12
+ import * as i7 from "./templates/toolbar-actions.template";
13
+ import * as i8 from "./common/toolbar-focusable.directive";
14
+ import * as i9 from "./localization/localized-messages.directive";
15
+ import * as i10 from "./common/output-card.component";
16
+ import * as i11 from "@angular/common";
17
+ import * as i12 from "@progress/kendo-angular-buttons";
18
+ import * as i13 from "@progress/kendo-angular-icons";
19
+ import * as i14 from "@progress/kendo-angular-inputs";
20
+ import * as i15 from "@progress/kendo-angular-layout";
21
+ export declare class AIPromptModule {
22
+ static ɵfac: i0.ɵɵFactoryDeclaration<AIPromptModule, never>;
23
+ static ɵmod: i0.ɵɵNgModuleDeclaration<AIPromptModule, [typeof i1.AIPromptComponent, typeof i2.PromptViewComponent, typeof i3.OutputViewComponent, typeof i4.CommandViewComponent, typeof i5.CustomViewComponent, typeof i6.AIPromptCustomMessagesComponent, typeof i7.AIPromptToolbarActionsDirective, typeof i8.AIPromptToolbarFocusableDirective, typeof i9.LocalizedMessagesDirective, typeof i10.AIPromptOutputCardComponent], [typeof i11.CommonModule, typeof i12.ButtonsModule, typeof i13.IconsModule, typeof i14.InputsModule, typeof i15.LayoutModule], [typeof i1.AIPromptComponent, typeof i2.PromptViewComponent, typeof i3.OutputViewComponent, typeof i4.CommandViewComponent, typeof i5.CustomViewComponent, typeof i6.AIPromptCustomMessagesComponent, typeof i7.AIPromptToolbarActionsDirective, typeof i8.AIPromptToolbarFocusableDirective]>;
24
+ static ɵinj: i0.ɵɵInjectorDeclaration<AIPromptModule>;
25
+ }
@@ -0,0 +1,26 @@
1
+ /**-----------------------------------------------------------------------------------------
2
+ * Copyright © 2024 Progress Software Corporation. All rights reserved.
3
+ * Licensed under commercial license. See LICENSE.md in the project root for more information
4
+ *-------------------------------------------------------------------------------------------*/
5
+ import { Subject } from 'rxjs';
6
+ import { AIPromptComponent } from '../aiprompt.component';
7
+ import { PromptCommand, PromptOutput, CommandExecuteEvent, PromptRequestEvent, OutputRatingChangeEvent } from '../models';
8
+ import * as i0 from "@angular/core";
9
+ /**
10
+ * @hidden
11
+ */
12
+ export declare class AIPromptService {
13
+ aiPrompt: AIPromptComponent;
14
+ promptValue: string;
15
+ showOutputRating: boolean;
16
+ requestEvent: Subject<PromptRequestEvent>;
17
+ executeEvent: Subject<CommandExecuteEvent>;
18
+ outputCopyEvent: Subject<PromptOutput>;
19
+ outputRatingChangeEvent: Subject<OutputRatingChangeEvent>;
20
+ promptCommands: Array<PromptCommand>;
21
+ promptOutputs: Array<PromptOutput>;
22
+ promptSuggestions: Array<string>;
23
+ getFlattenPromptCommands(commands?: Array<PromptCommand>): Array<PromptCommand>;
24
+ static ɵfac: i0.ɵɵFactoryDeclaration<AIPromptService, never>;
25
+ static ɵprov: i0.ɵɵInjectableDeclaration<AIPromptService>;
26
+ }
@@ -0,0 +1,36 @@
1
+ /**-----------------------------------------------------------------------------------------
2
+ * Copyright © 2024 Progress Software Corporation. All rights reserved.
3
+ * Licensed under commercial license. See LICENSE.md in the project root for more information
4
+ *-------------------------------------------------------------------------------------------*/
5
+ import { LocalizationService } from '@progress/kendo-angular-l10n';
6
+ import { SVGIcon } from '@progress/kendo-svg-icons';
7
+ import { PromptOutput, PromptOutputRating } from '../models/prompt-output.interface';
8
+ import { AIPromptService } from './aiprompt.service';
9
+ import * as i0 from "@angular/core";
10
+ /**
11
+ * @hidden
12
+ */
13
+ export declare class AIPromptOutputCardComponent {
14
+ private localization;
15
+ private service;
16
+ hostClass: boolean;
17
+ listItemRole: string;
18
+ tabIndex: number;
19
+ get ariaDescribedBy(): string;
20
+ ariaKeyShortcuts: string;
21
+ promptOutput: PromptOutput;
22
+ constructor(localization: LocalizationService, service: AIPromptService);
23
+ copyIcon: SVGIcon;
24
+ retryIcon: SVGIcon;
25
+ positiveRatingIcon: SVGIcon;
26
+ negativeRatingIcon: SVGIcon;
27
+ titleId: string;
28
+ messageFor(text: string): string;
29
+ get showRating(): boolean;
30
+ get outputTitle(): string;
31
+ handleRetry(): void;
32
+ handleCopy(): void;
33
+ handleRating(ratingType: PromptOutputRating): void;
34
+ static ɵfac: i0.ɵɵFactoryDeclaration<AIPromptOutputCardComponent, never>;
35
+ static ɵcmp: i0.ɵɵComponentDeclaration<AIPromptOutputCardComponent, "[kendoAIPromptOutputCard]", never, { "promptOutput": "promptOutput"; }, {}, never, never>;
36
+ }
@@ -0,0 +1,24 @@
1
+ /**-----------------------------------------------------------------------------------------
2
+ * Copyright © 2024 Progress Software Corporation. All rights reserved.
3
+ * Licensed under commercial license. See LICENSE.md in the project root for more information
4
+ *-------------------------------------------------------------------------------------------*/
5
+ import { ElementRef, OnDestroy, AfterViewInit, Renderer2 } from '@angular/core';
6
+ import { ToolbarNavigationService } from './toolbar-navigation.service';
7
+ import * as i0 from "@angular/core";
8
+ /**
9
+ * @hidden
10
+ */
11
+ export declare class AIPromptToolbarFocusableDirective implements AfterViewInit, OnDestroy {
12
+ private host;
13
+ private navigationService;
14
+ private renderer;
15
+ constructor(host: ElementRef, navigationService: ToolbarNavigationService, renderer: Renderer2);
16
+ private get element();
17
+ ngAfterViewInit(): void;
18
+ ngOnDestroy(): void;
19
+ activate(): void;
20
+ private keyDownHandler;
21
+ private clickHandler;
22
+ static ɵfac: i0.ɵɵFactoryDeclaration<AIPromptToolbarFocusableDirective, never>;
23
+ static ɵdir: i0.ɵɵDirectiveDeclaration<AIPromptToolbarFocusableDirective, "[kendoAIPromptToolbarFocusable]", never, {}, {}, never>;
24
+ }
@@ -0,0 +1,24 @@
1
+ /**-----------------------------------------------------------------------------------------
2
+ * Copyright © 2024 Progress Software Corporation. All rights reserved.
3
+ * Licensed under commercial license. See LICENSE.md in the project root for more information
4
+ *-------------------------------------------------------------------------------------------*/
5
+ import { LocalizationService } from '@progress/kendo-angular-l10n';
6
+ import { AIPromptToolbarFocusableDirective } from './toolbar-focusable.directive';
7
+ import * as i0 from "@angular/core";
8
+ /**
9
+ * @hidden
10
+ */
11
+ export declare class ToolbarNavigationService {
12
+ private localizationService;
13
+ focusableElements: AIPromptToolbarFocusableDirective[];
14
+ currentFocusedIndex: number;
15
+ constructor(localizationService: LocalizationService);
16
+ register(tool: AIPromptToolbarFocusableDirective): void;
17
+ unregister(tool: AIPromptToolbarFocusableDirective): void;
18
+ isActive(focusable: AIPromptToolbarFocusableDirective): boolean;
19
+ setActiveIndex(tool: AIPromptToolbarFocusableDirective): void;
20
+ move(direction: 'left' | 'right'): void;
21
+ focusFirst(): void;
22
+ static ɵfac: i0.ɵɵFactoryDeclaration<ToolbarNavigationService, never>;
23
+ static ɵprov: i0.ɵɵInjectableDeclaration<ToolbarNavigationService>;
24
+ }
@@ -0,0 +1,17 @@
1
+ /**-----------------------------------------------------------------------------------------
2
+ * Copyright © 2024 Progress Software Corporation. All rights reserved.
3
+ * Licensed under commercial license. See LICENSE.md in the project root for more information
4
+ *-------------------------------------------------------------------------------------------*/
5
+ import { LocalizationService } from '@progress/kendo-angular-l10n';
6
+ import { Messages } from './messages';
7
+ import * as i0 from "@angular/core";
8
+ /**
9
+ * Custom component messages override default component messages.
10
+ */
11
+ export declare class AIPromptCustomMessagesComponent extends Messages {
12
+ protected service: LocalizationService;
13
+ constructor(service: LocalizationService);
14
+ protected get override(): boolean;
15
+ static ɵfac: i0.ɵɵFactoryDeclaration<AIPromptCustomMessagesComponent, never>;
16
+ static ɵcmp: i0.ɵɵComponentDeclaration<AIPromptCustomMessagesComponent, "kendo-aiprompt-messages", never, {}, {}, never, never>;
17
+ }
@@ -0,0 +1,16 @@
1
+ /**-----------------------------------------------------------------------------------------
2
+ * Copyright © 2024 Progress Software Corporation. All rights reserved.
3
+ * Licensed under commercial license. See LICENSE.md in the project root for more information
4
+ *-------------------------------------------------------------------------------------------*/
5
+ import { LocalizationService } from '@progress/kendo-angular-l10n';
6
+ import { Messages } from './messages';
7
+ import * as i0 from "@angular/core";
8
+ /**
9
+ * @hidden
10
+ */
11
+ export declare class LocalizedMessagesDirective extends Messages {
12
+ protected service: LocalizationService;
13
+ constructor(service: LocalizationService);
14
+ static ɵfac: i0.ɵɵFactoryDeclaration<LocalizedMessagesDirective, never>;
15
+ static ɵdir: i0.ɵɵDirectiveDeclaration<LocalizedMessagesDirective, "[kendoAIPromptLocalizedMessages]", never, {}, {}, never>;
16
+ }
@@ -0,0 +1,49 @@
1
+ /**-----------------------------------------------------------------------------------------
2
+ * Copyright © 2024 Progress Software Corporation. All rights reserved.
3
+ * Licensed under commercial license. See LICENSE.md in the project root for more information
4
+ *-------------------------------------------------------------------------------------------*/
5
+ import { ComponentMessages } from '@progress/kendo-angular-l10n';
6
+ import * as i0 from "@angular/core";
7
+ /**
8
+ * @hidden
9
+ */
10
+ export declare class Messages extends ComponentMessages {
11
+ /**
12
+ * The Toolbar button text for the Prompt view.
13
+ */
14
+ promptView: string;
15
+ /**
16
+ * The Toolbar button text for the Output view.
17
+ */
18
+ outputView: string;
19
+ /**
20
+ * The text for the Generate button in the Prompt view.
21
+ */
22
+ generateOutput: string;
23
+ /**
24
+ * The placeholder text for the Prompt view textarea.
25
+ */
26
+ promptPlaceholder: string;
27
+ /**
28
+ * The Copy button text in each Output view card.
29
+ */
30
+ copyOutput: string;
31
+ /**
32
+ * The Retry button text in each Output view card.
33
+ */
34
+ retryGeneration: string;
35
+ /**
36
+ * The title of each Output view card.
37
+ */
38
+ outputTitle: string;
39
+ /**
40
+ * The title of each Output view retry card.
41
+ */
42
+ outputRetryTitle: string;
43
+ /**
44
+ * The title of the Prompt suggestions button.
45
+ */
46
+ promptSuggestions: string;
47
+ static ɵfac: i0.ɵɵFactoryDeclaration<Messages, never>;
48
+ static ɵdir: i0.ɵɵDirectiveDeclaration<Messages, never, never, { "promptView": "promptView"; "outputView": "outputView"; "generateOutput": "generateOutput"; "promptPlaceholder": "promptPlaceholder"; "copyOutput": "copyOutput"; "retryGeneration": "retryGeneration"; "outputTitle": "outputTitle"; "outputRetryTitle": "outputRetryTitle"; "promptSuggestions": "promptSuggestions"; }, {}, never>;
49
+ }
@@ -0,0 +1,23 @@
1
+ /**-----------------------------------------------------------------------------------------
2
+ * Copyright © 2024 Progress Software Corporation. All rights reserved.
3
+ * Licensed under commercial license. See LICENSE.md in the project root for more information
4
+ *-------------------------------------------------------------------------------------------*/
5
+ import { AIPromptComponent } from "../aiprompt.component";
6
+ import { PromptCommand } from "./command.interface";
7
+ /**
8
+ * Arguments for the `commandExecute` event of the AIPrompt.
9
+ */
10
+ export interface CommandExecuteEvent {
11
+ /**
12
+ * The selected command.
13
+ */
14
+ command: PromptCommand;
15
+ /**
16
+ * The AIPrompt component instance.
17
+ */
18
+ sender: AIPromptComponent;
19
+ /**
20
+ * Specifies if the event is triggered by the Retry button.
21
+ */
22
+ isRetry: boolean;
23
+ }
@@ -0,0 +1,30 @@
1
+ /**-----------------------------------------------------------------------------------------
2
+ * Copyright © 2024 Progress Software Corporation. All rights reserved.
3
+ * Licensed under commercial license. See LICENSE.md in the project root for more information
4
+ *-------------------------------------------------------------------------------------------*/
5
+ import { SVGIcon } from "@progress/kendo-svg-icons";
6
+ /**
7
+ * An interface for the Action View commands.
8
+ */
9
+ export interface PromptCommand {
10
+ /**
11
+ * The unique identifier of the command.
12
+ */
13
+ id: string | number;
14
+ /**
15
+ * Specifies the command text.
16
+ */
17
+ text?: string;
18
+ /**
19
+ * Specifies the name of the [font icon]({% slug icons %}#toc-list-of-font-icons) that will be rendered for the command.
20
+ */
21
+ icon?: string;
22
+ /**
23
+ * Specifies the name of the [SVG icon]({% slug svgicon_list %}) that will be rendered for the command.
24
+ */
25
+ svgIcon?: SVGIcon;
26
+ /**
27
+ * Defines the child commands as an array.
28
+ */
29
+ children?: Array<PromptCommand>;
30
+ }
@@ -0,0 +1,10 @@
1
+ /**-----------------------------------------------------------------------------------------
2
+ * Copyright © 2024 Progress Software Corporation. All rights reserved.
3
+ * Licensed under commercial license. See LICENSE.md in the project root for more information
4
+ *-------------------------------------------------------------------------------------------*/
5
+ export { CommandExecuteEvent } from './command-execute-event';
6
+ export { PromptCommand } from './command.interface';
7
+ export { PromptOutput } from './prompt-output.interface';
8
+ export { PromptRequestEvent } from './prompt-request-event';
9
+ export { PromptOutputRating } from './prompt-output.interface';
10
+ export { OutputRatingChangeEvent } from './output-rating-change-event';
@@ -0,0 +1,18 @@
1
+ /**-----------------------------------------------------------------------------------------
2
+ * Copyright © 2024 Progress Software Corporation. All rights reserved.
3
+ * Licensed under commercial license. See LICENSE.md in the project root for more information
4
+ *-------------------------------------------------------------------------------------------*/
5
+ import { PromptOutput, PromptOutputRating } from "./prompt-output.interface";
6
+ /**
7
+ * Arguments for the `outputRatingChange` event of the AIPrompt.
8
+ */
9
+ export interface OutputRatingChangeEvent {
10
+ /**
11
+ * The selected command.
12
+ */
13
+ promptOutput: PromptOutput;
14
+ /**
15
+ * The prompt output rating.
16
+ */
17
+ rating: PromptOutputRating;
18
+ }
@@ -0,0 +1,41 @@
1
+ /**-----------------------------------------------------------------------------------------
2
+ * Copyright © 2024 Progress Software Corporation. All rights reserved.
3
+ * Licensed under commercial license. See LICENSE.md in the project root for more information
4
+ *-------------------------------------------------------------------------------------------*/
5
+ /**
6
+ * An interface for the Prompt Output section.
7
+ */
8
+ export interface PromptOutput {
9
+ /**
10
+ * The unique identifier of the prompt output.
11
+ */
12
+ id: number | string;
13
+ /**
14
+ * The text content of the prompt output.
15
+ */
16
+ output: string;
17
+ /**
18
+ * The prompt that initiated the output generation.
19
+ */
20
+ prompt: string;
21
+ /**
22
+ * An optional custom title for the prompt section.
23
+ */
24
+ title?: string;
25
+ /**
26
+ * Specifies if the prompt generation was initiated via the retry button.
27
+ */
28
+ isRetry?: boolean;
29
+ /**
30
+ * Optionally specifies a command id, if the prompt generation was triggered via a command.
31
+ */
32
+ commandId?: string | number;
33
+ /**
34
+ * Optionally specifies the rating for the prompt output.
35
+ */
36
+ rating?: PromptOutputRating;
37
+ }
38
+ /**
39
+ * Represents the rating of the prompt outputs.
40
+ */
41
+ export declare type PromptOutputRating = "positive" | "negative";
@@ -0,0 +1,22 @@
1
+ /**-----------------------------------------------------------------------------------------
2
+ * Copyright © 2024 Progress Software Corporation. All rights reserved.
3
+ * Licensed under commercial license. See LICENSE.md in the project root for more information
4
+ *-------------------------------------------------------------------------------------------*/
5
+ import { AIPromptComponent } from "../aiprompt.component";
6
+ /**
7
+ * Arguments for the `promptRequest` event of the AIPrompt.
8
+ */
9
+ export interface PromptRequestEvent {
10
+ /**
11
+ * The user prompt input.
12
+ */
13
+ prompt: string;
14
+ /**
15
+ * The AIPrompt component instance.
16
+ */
17
+ sender: AIPromptComponent;
18
+ /**
19
+ * Specifies if the event is triggered by the retry button.
20
+ */
21
+ isRetry: boolean;
22
+ }
@@ -0,0 +1,8 @@
1
+ /**-----------------------------------------------------------------------------------------
2
+ * Copyright © 2024 Progress Software Corporation. All rights reserved.
3
+ * Licensed under commercial license. See LICENSE.md in the project root for more information
4
+ *-------------------------------------------------------------------------------------------*/
5
+ /**
6
+ * @hidden
7
+ */
8
+ export declare type ViewType = 'prompt' | 'output' | 'command' | 'custom';
@@ -0,0 +1,18 @@
1
+ /**-----------------------------------------------------------------------------------------
2
+ * Copyright © 2024 Progress Software Corporation. All rights reserved.
3
+ * Licensed under commercial license. See LICENSE.md in the project root for more information
4
+ *-------------------------------------------------------------------------------------------*/
5
+ import { TemplateRef } from '@angular/core';
6
+ import * as i0 from "@angular/core";
7
+ /**
8
+ * Represents a template that allows you to define additional ToolBar actions.
9
+ * The actions will be rendered right after all views' ToolBar buttons.
10
+ * To define the template, nest an `<ng-template>` tag
11
+ * with the `kendoAIPromptToolbarActionsTemplate` directive inside the `<kendo-aiprompt>` tag.
12
+ */
13
+ export declare class AIPromptToolbarActionsDirective {
14
+ templateRef: TemplateRef<any>;
15
+ constructor(templateRef: TemplateRef<any>);
16
+ static ɵfac: i0.ɵɵFactoryDeclaration<AIPromptToolbarActionsDirective, [{ optional: true; }]>;
17
+ static ɵdir: i0.ɵɵDirectiveDeclaration<AIPromptToolbarActionsDirective, "[kendoAIPromptToolbarActionsTemplate]", never, {}, {}, never>;
18
+ }
@@ -0,0 +1,19 @@
1
+ /**-----------------------------------------------------------------------------------------
2
+ * Copyright © 2024 Progress Software Corporation. All rights reserved.
3
+ * Licensed under commercial license. See LICENSE.md in the project root for more information
4
+ *-------------------------------------------------------------------------------------------*/
5
+ import { InjectionToken } from "@angular/core";
6
+ import { ViewType } from "./models/view-type";
7
+ import { SVGIcon } from "@progress/kendo-svg-icons";
8
+ /**
9
+ * @hidden
10
+ */
11
+ export declare const MY_TOKEN: InjectionToken<ViewType>;
12
+ /**
13
+ * @hidden
14
+ */
15
+ export declare const DEFAULT_SVG_ICONS: Partial<Record<ViewType, SVGIcon>>;
16
+ /**
17
+ * @hidden
18
+ */
19
+ export declare const DEFAULT_ICONS: Partial<Record<ViewType, string>>;
@@ -0,0 +1,46 @@
1
+ /**-----------------------------------------------------------------------------------------
2
+ * Copyright © 2024 Progress Software Corporation. All rights reserved.
3
+ * Licensed under commercial license. See LICENSE.md in the project root for more information
4
+ *-------------------------------------------------------------------------------------------*/
5
+ import { TemplateRef } from '@angular/core';
6
+ import { SVGIcon } from '@progress/kendo-svg-icons';
7
+ import { LocalizationService } from '@progress/kendo-angular-l10n';
8
+ import { ViewType } from '../models/view-type';
9
+ import * as i0 from "@angular/core";
10
+ /**
11
+ * @hidden
12
+ */
13
+ export declare abstract class BaseView {
14
+ viewType: ViewType;
15
+ private localization;
16
+ hostClasses: boolean;
17
+ /**
18
+ * @hidden
19
+ */
20
+ template: TemplateRef<any>;
21
+ constructor(viewType: ViewType, localization: LocalizationService);
22
+ /**
23
+ * The text of the ToolBar button corresponding to the view.
24
+ */
25
+ set buttonText(value: string);
26
+ get buttonText(): string;
27
+ /**
28
+ * The font icon of the ToolBar button corresponding to the view.
29
+ */
30
+ set icon(value: string);
31
+ get icon(): string;
32
+ /**
33
+ * The SVG icon of the ToolBar button corresponding to the view.
34
+ */
35
+ set svgIcon(value: SVGIcon);
36
+ get svgIcon(): SVGIcon;
37
+ /**
38
+ * @hidden
39
+ */
40
+ messageFor(text: string): string;
41
+ private _buttonText;
42
+ private _icon;
43
+ private _svgIcon;
44
+ static ɵfac: i0.ɵɵFactoryDeclaration<BaseView, never>;
45
+ static ɵdir: i0.ɵɵDirectiveDeclaration<BaseView, never, never, { "buttonText": "buttonText"; "icon": "icon"; "svgIcon": "svgIcon"; }, {}, never>;
46
+ }
@@ -0,0 +1,23 @@
1
+ /**-----------------------------------------------------------------------------------------
2
+ * Copyright © 2024 Progress Software Corporation. All rights reserved.
3
+ * Licensed under commercial license. See LICENSE.md in the project root for more information
4
+ *-------------------------------------------------------------------------------------------*/
5
+ import { OnInit } from '@angular/core';
6
+ import { LocalizationService } from '@progress/kendo-angular-l10n';
7
+ import { BaseView } from './base-view';
8
+ import { AIPromptService } from '../common/aiprompt.service';
9
+ import { PanelBarItemModel, PanelBarItemClickEvent } from '@progress/kendo-angular-layout';
10
+ import * as i0 from "@angular/core";
11
+ /**
12
+ * The component for rendering the **Command** view.
13
+ */
14
+ export declare class CommandViewComponent extends BaseView implements OnInit {
15
+ private service;
16
+ constructor(localization: LocalizationService, service: AIPromptService);
17
+ panelBarItems: Array<PanelBarItemModel>;
18
+ ngOnInit(): void;
19
+ itemClickHandler(ev: PanelBarItemClickEvent): void;
20
+ private getPanelBarItems;
21
+ static ɵfac: i0.ɵɵFactoryDeclaration<CommandViewComponent, never>;
22
+ static ɵcmp: i0.ɵɵComponentDeclaration<CommandViewComponent, "kendo-aiprompt-command-view", never, {}, {}, never, never>;
23
+ }
@@ -0,0 +1,20 @@
1
+ /**-----------------------------------------------------------------------------------------
2
+ * Copyright © 2024 Progress Software Corporation. All rights reserved.
3
+ * Licensed under commercial license. See LICENSE.md in the project root for more information
4
+ *-------------------------------------------------------------------------------------------*/
5
+ import { TemplateRef } from '@angular/core';
6
+ import { LocalizationService } from '@progress/kendo-angular-l10n';
7
+ import { BaseView } from './base-view';
8
+ import * as i0 from "@angular/core";
9
+ /**
10
+ * The component for rendering a **Custom** view.
11
+ */
12
+ export declare class CustomViewComponent extends BaseView {
13
+ constructor(localization: LocalizationService);
14
+ /**
15
+ * Sets the content of the Custom view as a template reference.
16
+ */
17
+ viewTemplate: TemplateRef<any>;
18
+ static ɵfac: i0.ɵɵFactoryDeclaration<CustomViewComponent, never>;
19
+ static ɵcmp: i0.ɵɵComponentDeclaration<CustomViewComponent, "kendo-aiprompt-custom-view", never, { "viewTemplate": "viewTemplate"; }, {}, never, never>;
20
+ }
@@ -0,0 +1,8 @@
1
+ /**-----------------------------------------------------------------------------------------
2
+ * Copyright © 2024 Progress Software Corporation. All rights reserved.
3
+ * Licensed under commercial license. See LICENSE.md in the project root for more information
4
+ *-------------------------------------------------------------------------------------------*/
5
+ export { CommandViewComponent } from './command-view.component';
6
+ export { CustomViewComponent } from './custom-view.component';
7
+ export { OutputViewComponent } from './output-view.component';
8
+ export { PromptViewComponent } from './prompt-view.component';