@tilde-nlp/ngx-common 4.1.57 → 4.1.59
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/esm2022/lib/llm/llm.component.mjs +3 -3
- package/esm2022/lib/services/quota/models/quota-service-configuration.model.mjs +1 -1
- package/esm2022/lib/services/quota/quota.service.mjs +5 -3
- package/fesm2022/tilde-nlp-ngx-common.mjs +5 -4
- package/fesm2022/tilde-nlp-ngx-common.mjs.map +1 -1
- package/lib/services/quota/models/quota-service-configuration.model.d.ts +2 -0
- package/lib/services/quota/quota.service.d.ts +1 -1
- package/package.json +1 -1
|
@@ -37,11 +37,11 @@ export class LLMComponent {
|
|
|
37
37
|
});
|
|
38
38
|
}
|
|
39
39
|
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: LLMComponent, deps: [{ token: i1.MatDialog }, { token: i2.IconService }, { token: i2.LanguageTranslateService }], target: i0.ɵɵFactoryTarget.Component }); }
|
|
40
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "16.2.12", type: LLMComponent, selector: "lib-llm", inputs: { text: "text", language: "language", isMenuDisabled: "isMenuDisabled", rephrasableLanguagesCodeList: "rephrasableLanguagesCodeList" }, ngImport: i0, template: "<button\r\n [disabled]=\"isMenuDisabled\"\r\n [matTooltip]=\"'LLM.MENU_TOOLTIP' | translate\"\r\n mat-icon-button\r\n [matMenuTriggerFor]=\"menu\"\r\n>\r\n <mat-icon svgIcon=\"llm_menu\"></mat-icon>\r\n</button>\r\n\r\n<mat-menu #menu=\"matMenu\">\r\n <div [matTooltip]=\"!isTextSummarizable ? ('LLM.MENU_SUMMARY_DISABLED_TOOLTIP' | translate) : ''\">\r\n <button\r\n mat-menu-item\r\n [disabled]=\"!isTextSummarizable\"\r\n (click)=\"openLLMModal(llmAction.SUMMARY)\"\r\n >\r\n {{ \"LLM.SUMMARY\" | translate }}\r\n </button>\r\n </div>\r\n\r\n <div [matTooltip]=\"!isTargetLanguageRephrasable ? ('LLM.MENU_REPHRASE_DISABLED_TOOLTIP' | translate) : ''\">\r\n <button\r\n mat-menu-item\r\n [disabled]=\"!isTargetLanguageRephrasable\"\r\n (click)=\"openLLMModal(llmAction.REPHRASE)\"\r\n >\r\n {{ \"LLM.REPHRASE\" | translate }}\r\n </button>\r\n </div>\r\n</mat-menu>\r\n", styles: [""], dependencies: [{ kind: "component", type: i3.MatIconButton, selector: "button[mat-icon-button]", inputs: ["disabled", "disableRipple", "color"], exportAs: ["matButton"] }, { kind: "component", type: i4.MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }, { kind: "component", type: i5.MatMenu, selector: "mat-menu", exportAs: ["matMenu"] }, { kind: "component", type: i5.MatMenuItem, selector: "[mat-menu-item]", inputs: ["disabled", "disableRipple", "role"], exportAs: ["matMenuItem"] }, { kind: "directive", type: i5.MatMenuTrigger, selector: "[mat-menu-trigger-for], [matMenuTriggerFor]", exportAs: ["matMenuTrigger"] }, { kind: "directive", type: i6.MatTooltip, selector: "[matTooltip]", exportAs: ["matTooltip"] }, { kind: "pipe", type: i7.TranslatePipe, name: "translate" }] }); }
|
|
40
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "16.2.12", type: LLMComponent, selector: "lib-llm", inputs: { text: "text", language: "language", isMenuDisabled: "isMenuDisabled", rephrasableLanguagesCodeList: "rephrasableLanguagesCodeList" }, ngImport: i0, template: "<button\r\n [disabled]=\"isMenuDisabled\"\r\n [matTooltip]=\"'LLM.MENU_TOOLTIP' | translate\"\r\n mat-icon-button\r\n [matMenuTriggerFor]=\"menu\"\r\n>\r\n <mat-icon svgIcon=\"llm_menu\"></mat-icon>\r\n</button>\r\n\r\n<mat-menu #menu=\"matMenu\">\r\n <div [matTooltipPosition]=\"'left'\" [matTooltip]=\"!isTextSummarizable ? ('LLM.MENU_SUMMARY_DISABLED_TOOLTIP' | translate) : ''\">\r\n <button\r\n mat-menu-item\r\n [disabled]=\"!isTextSummarizable\"\r\n (click)=\"openLLMModal(llmAction.SUMMARY)\"\r\n >\r\n {{ \"LLM.SUMMARY\" | translate }}\r\n </button>\r\n </div>\r\n\r\n <div [matTooltipPosition]=\"'left'\" [matTooltip]=\"!isTargetLanguageRephrasable ? ('LLM.MENU_REPHRASE_DISABLED_TOOLTIP' | translate) : ''\">\r\n <button\r\n mat-menu-item\r\n [disabled]=\"!isTargetLanguageRephrasable\"\r\n (click)=\"openLLMModal(llmAction.REPHRASE)\"\r\n >\r\n {{ \"LLM.REPHRASE\" | translate }}\r\n </button>\r\n </div>\r\n</mat-menu>\r\n", styles: [""], dependencies: [{ kind: "component", type: i3.MatIconButton, selector: "button[mat-icon-button]", inputs: ["disabled", "disableRipple", "color"], exportAs: ["matButton"] }, { kind: "component", type: i4.MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }, { kind: "component", type: i5.MatMenu, selector: "mat-menu", exportAs: ["matMenu"] }, { kind: "component", type: i5.MatMenuItem, selector: "[mat-menu-item]", inputs: ["disabled", "disableRipple", "role"], exportAs: ["matMenuItem"] }, { kind: "directive", type: i5.MatMenuTrigger, selector: "[mat-menu-trigger-for], [matMenuTriggerFor]", exportAs: ["matMenuTrigger"] }, { kind: "directive", type: i6.MatTooltip, selector: "[matTooltip]", exportAs: ["matTooltip"] }, { kind: "pipe", type: i7.TranslatePipe, name: "translate" }] }); }
|
|
41
41
|
}
|
|
42
42
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: LLMComponent, decorators: [{
|
|
43
43
|
type: Component,
|
|
44
|
-
args: [{ selector: 'lib-llm', template: "<button\r\n [disabled]=\"isMenuDisabled\"\r\n [matTooltip]=\"'LLM.MENU_TOOLTIP' | translate\"\r\n mat-icon-button\r\n [matMenuTriggerFor]=\"menu\"\r\n>\r\n <mat-icon svgIcon=\"llm_menu\"></mat-icon>\r\n</button>\r\n\r\n<mat-menu #menu=\"matMenu\">\r\n <div [matTooltip]=\"!isTextSummarizable ? ('LLM.MENU_SUMMARY_DISABLED_TOOLTIP' | translate) : ''\">\r\n <button\r\n mat-menu-item\r\n [disabled]=\"!isTextSummarizable\"\r\n (click)=\"openLLMModal(llmAction.SUMMARY)\"\r\n >\r\n {{ \"LLM.SUMMARY\" | translate }}\r\n </button>\r\n </div>\r\n\r\n <div [matTooltip]=\"!isTargetLanguageRephrasable ? ('LLM.MENU_REPHRASE_DISABLED_TOOLTIP' | translate) : ''\">\r\n <button\r\n mat-menu-item\r\n [disabled]=\"!isTargetLanguageRephrasable\"\r\n (click)=\"openLLMModal(llmAction.REPHRASE)\"\r\n >\r\n {{ \"LLM.REPHRASE\" | translate }}\r\n </button>\r\n </div>\r\n</mat-menu>\r\n" }]
|
|
44
|
+
args: [{ selector: 'lib-llm', template: "<button\r\n [disabled]=\"isMenuDisabled\"\r\n [matTooltip]=\"'LLM.MENU_TOOLTIP' | translate\"\r\n mat-icon-button\r\n [matMenuTriggerFor]=\"menu\"\r\n>\r\n <mat-icon svgIcon=\"llm_menu\"></mat-icon>\r\n</button>\r\n\r\n<mat-menu #menu=\"matMenu\">\r\n <div [matTooltipPosition]=\"'left'\" [matTooltip]=\"!isTextSummarizable ? ('LLM.MENU_SUMMARY_DISABLED_TOOLTIP' | translate) : ''\">\r\n <button\r\n mat-menu-item\r\n [disabled]=\"!isTextSummarizable\"\r\n (click)=\"openLLMModal(llmAction.SUMMARY)\"\r\n >\r\n {{ \"LLM.SUMMARY\" | translate }}\r\n </button>\r\n </div>\r\n\r\n <div [matTooltipPosition]=\"'left'\" [matTooltip]=\"!isTargetLanguageRephrasable ? ('LLM.MENU_REPHRASE_DISABLED_TOOLTIP' | translate) : ''\">\r\n <button\r\n mat-menu-item\r\n [disabled]=\"!isTargetLanguageRephrasable\"\r\n (click)=\"openLLMModal(llmAction.REPHRASE)\"\r\n >\r\n {{ \"LLM.REPHRASE\" | translate }}\r\n </button>\r\n </div>\r\n</mat-menu>\r\n" }]
|
|
45
45
|
}], ctorParameters: function () { return [{ type: i1.MatDialog }, { type: i2.IconService }, { type: i2.LanguageTranslateService }]; }, propDecorators: { text: [{
|
|
46
46
|
type: Input
|
|
47
47
|
}], language: [{
|
|
@@ -51,4 +51,4 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.12", ngImpo
|
|
|
51
51
|
}], rephrasableLanguagesCodeList: [{
|
|
52
52
|
type: Input
|
|
53
53
|
}] } });
|
|
54
|
-
//# sourceMappingURL=data:application/json;base64,
|
|
54
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoibGxtLmNvbXBvbmVudC5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbIi4uLy4uLy4uLy4uLy4uL3Byb2plY3RzL25neC1jb21tb24vc3JjL2xpYi9sbG0vbGxtLmNvbXBvbmVudC50cyIsIi4uLy4uLy4uLy4uLy4uL3Byb2plY3RzL25neC1jb21tb24vc3JjL2xpYi9sbG0vbGxtLmNvbXBvbmVudC5odG1sIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiJBQUFBLE9BQU8sRUFBRSxTQUFTLEVBQUUsS0FBSyxFQUFFLE1BQU0sZUFBZSxDQUFDO0FBQ2pELE9BQU8sRUFBRSxVQUFVLEVBQUUsTUFBTSwyQkFBMkIsQ0FBQztBQUd2RCxPQUFPLEVBQUUsK0JBQStCLEVBQUUsTUFBTSw0RUFBNEUsQ0FBQztBQUM3SCxPQUFPLEtBQUssS0FBSyxNQUFNLFNBQVMsQ0FBQzs7Ozs7Ozs7O0FBT2pDLE1BQU0sT0FBTyxZQUFZO0lBUXZCLElBQUksa0JBQWtCO1FBQ3BCLE9BQU8sSUFBSSxDQUFDLElBQUksQ0FBQyxNQUFNLEdBQUcsR0FBRy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ESVNBQkxFRF9UT09MVElQJyB8IHRyYW5zbGF0ZSkgOiAnJ1wiPlxyXG4gICAgPGJ1dHRvblxyXG4gICAgICBtYXQtbWVudS1pdGVtXHJcbiAgICAgIFtkaXNhYmxlZF09XCIhaXNUYXJnZXRMYW5ndWFnZVJlcGhyYXNhYmxlXCJcclxuICAgICAgKGNsaWNrKT1cIm9wZW5MTE1Nb2RhbChsbG1BY3Rpb24uUkVQSFJBU0UpXCJcclxuICAgID5cclxuICAgICAge3sgXCJMTE0uUkVQSFJBU0VcIiB8IHRyYW5zbGF0ZSB9fVxyXG4gICAgPC9idXR0b24+XHJcbiAgPC9kaXY+XHJcbjwvbWF0LW1lbnU+XHJcbiJdfQ==
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
export {};
|
|
2
|
-
//# sourceMappingURL=data:application/json;base64,
|
|
2
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoicXVvdGEtc2VydmljZS1jb25maWd1cmF0aW9uLm1vZGVsLmpzIiwic291cmNlUm9vdCI6IiIsInNvdXJjZXMiOlsiLi4vLi4vLi4vLi4vLi4vLi4vLi4vcHJvamVjdHMvbmd4LWNvbW1vbi9zcmMvbGliL3NlcnZpY2VzL3F1b3RhL21vZGVscy9xdW90YS1zZXJ2aWNlLWNvbmZpZ3VyYXRpb24ubW9kZWwudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IiIsInNvdXJjZXNDb250ZW50IjpbImV4cG9ydCBpbnRlcmZhY2UgUXVvdGFTZXJ2aWNlQ29uZmlndXJhdGlvbiB7XHJcbiAgYXBpVXJsOiBzdHJpbmc7XHJcbiAgeEFwaUtleTogc3RyaW5nO1xyXG4gIGFwcElkOiBzdHJpbmc7XHJcbn0iXX0=
|
|
@@ -1,14 +1,16 @@
|
|
|
1
1
|
import { Inject, Injectable } from '@angular/core';
|
|
2
2
|
import { QUOTA_SERVICE_CONFIGURATION_TOKEN } from './injection-tokens/quota-service-configuration.token';
|
|
3
|
+
import { AuthHeadersHelper } from '../../helpers';
|
|
3
4
|
import * as i0 from "@angular/core";
|
|
4
5
|
import * as i1 from "@angular/common/http";
|
|
5
6
|
export class QuotaService {
|
|
6
7
|
constructor(http, config) {
|
|
7
8
|
this.http = http;
|
|
8
|
-
this.
|
|
9
|
+
this.config = config;
|
|
9
10
|
}
|
|
10
11
|
getQuotaUsage() {
|
|
11
|
-
|
|
12
|
+
const headers = AuthHeadersHelper.getApiV2AuthHeaders(this.config.xApiKey, this.config.appId);
|
|
13
|
+
return this.http.get(this.config.apiUrl, { headers });
|
|
12
14
|
}
|
|
13
15
|
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: QuotaService, deps: [{ token: i1.HttpClient }, { token: QUOTA_SERVICE_CONFIGURATION_TOKEN }], target: i0.ɵɵFactoryTarget.Injectable }); }
|
|
14
16
|
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: QuotaService, providedIn: 'root' }); }
|
|
@@ -22,4 +24,4 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.12", ngImpo
|
|
|
22
24
|
type: Inject,
|
|
23
25
|
args: [QUOTA_SERVICE_CONFIGURATION_TOKEN]
|
|
24
26
|
}] }]; } });
|
|
25
|
-
//# sourceMappingURL=data:application/json;base64,
|
|
27
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoicXVvdGEuc2VydmljZS5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbIi4uLy4uLy4uLy4uLy4uLy4uL3Byb2plY3RzL25neC1jb21tb24vc3JjL2xpYi9zZXJ2aWNlcy9xdW90YS9xdW90YS5zZXJ2aWNlLnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiJBQUNBLE9BQU8sRUFBRSxNQUFNLEVBQUUsVUFBVS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BRdW90YVVzYWdlW10gfT4odGhpcy5jb25maWcuYXBpVXJsLCB7IGhlYWRlcnMgfSk7XHJcbiAgfVxyXG59XHJcbiJdfQ==
|
|
@@ -1336,10 +1336,11 @@ const QUOTA_SERVICE_CONFIGURATION_TOKEN = 'QUOTA_SERVICE_CONFIGURATION_TOKEN';
|
|
|
1336
1336
|
class QuotaService {
|
|
1337
1337
|
constructor(http, config) {
|
|
1338
1338
|
this.http = http;
|
|
1339
|
-
this.
|
|
1339
|
+
this.config = config;
|
|
1340
1340
|
}
|
|
1341
1341
|
getQuotaUsage() {
|
|
1342
|
-
|
|
1342
|
+
const headers = AuthHeadersHelper.getApiV2AuthHeaders(this.config.xApiKey, this.config.appId);
|
|
1343
|
+
return this.http.get(this.config.apiUrl, { headers });
|
|
1343
1344
|
}
|
|
1344
1345
|
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: QuotaService, deps: [{ token: i1$2.HttpClient }, { token: QUOTA_SERVICE_CONFIGURATION_TOKEN }], target: i0.ɵɵFactoryTarget.Injectable }); }
|
|
1345
1346
|
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: QuotaService, providedIn: 'root' }); }
|
|
@@ -4731,11 +4732,11 @@ class LLMComponent {
|
|
|
4731
4732
|
});
|
|
4732
4733
|
}
|
|
4733
4734
|
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: LLMComponent, deps: [{ token: i1$3.MatDialog }, { token: IconService }, { token: LanguageTranslateService }], target: i0.ɵɵFactoryTarget.Component }); }
|
|
4734
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "16.2.12", type: LLMComponent, selector: "lib-llm", inputs: { text: "text", language: "language", isMenuDisabled: "isMenuDisabled", rephrasableLanguagesCodeList: "rephrasableLanguagesCodeList" }, ngImport: i0, template: "<button\r\n [disabled]=\"isMenuDisabled\"\r\n [matTooltip]=\"'LLM.MENU_TOOLTIP' | translate\"\r\n mat-icon-button\r\n [matMenuTriggerFor]=\"menu\"\r\n>\r\n <mat-icon svgIcon=\"llm_menu\"></mat-icon>\r\n</button>\r\n\r\n<mat-menu #menu=\"matMenu\">\r\n <div [matTooltip]=\"!isTextSummarizable ? ('LLM.MENU_SUMMARY_DISABLED_TOOLTIP' | translate) : ''\">\r\n <button\r\n mat-menu-item\r\n [disabled]=\"!isTextSummarizable\"\r\n (click)=\"openLLMModal(llmAction.SUMMARY)\"\r\n >\r\n {{ \"LLM.SUMMARY\" | translate }}\r\n </button>\r\n </div>\r\n\r\n <div [matTooltip]=\"!isTargetLanguageRephrasable ? ('LLM.MENU_REPHRASE_DISABLED_TOOLTIP' | translate) : ''\">\r\n <button\r\n mat-menu-item\r\n [disabled]=\"!isTargetLanguageRephrasable\"\r\n (click)=\"openLLMModal(llmAction.REPHRASE)\"\r\n >\r\n {{ \"LLM.REPHRASE\" | translate }}\r\n </button>\r\n </div>\r\n</mat-menu>\r\n", styles: [""], dependencies: [{ kind: "component", type: i4.MatIconButton, selector: "button[mat-icon-button]", inputs: ["disabled", "disableRipple", "color"], exportAs: ["matButton"] }, { kind: "component", type: i1.MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }, { kind: "component", type: i5.MatMenu, selector: "mat-menu", exportAs: ["matMenu"] }, { kind: "component", type: i5.MatMenuItem, selector: "[mat-menu-item]", inputs: ["disabled", "disableRipple", "role"], exportAs: ["matMenuItem"] }, { kind: "directive", type: i5.MatMenuTrigger, selector: "[mat-menu-trigger-for], [matMenuTriggerFor]", exportAs: ["matMenuTrigger"] }, { kind: "directive", type: i2$1.MatTooltip, selector: "[matTooltip]", exportAs: ["matTooltip"] }, { kind: "pipe", type: i1$1.TranslatePipe, name: "translate" }] }); }
|
|
4735
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "16.2.12", type: LLMComponent, selector: "lib-llm", inputs: { text: "text", language: "language", isMenuDisabled: "isMenuDisabled", rephrasableLanguagesCodeList: "rephrasableLanguagesCodeList" }, ngImport: i0, template: "<button\r\n [disabled]=\"isMenuDisabled\"\r\n [matTooltip]=\"'LLM.MENU_TOOLTIP' | translate\"\r\n mat-icon-button\r\n [matMenuTriggerFor]=\"menu\"\r\n>\r\n <mat-icon svgIcon=\"llm_menu\"></mat-icon>\r\n</button>\r\n\r\n<mat-menu #menu=\"matMenu\">\r\n <div [matTooltipPosition]=\"'left'\" [matTooltip]=\"!isTextSummarizable ? ('LLM.MENU_SUMMARY_DISABLED_TOOLTIP' | translate) : ''\">\r\n <button\r\n mat-menu-item\r\n [disabled]=\"!isTextSummarizable\"\r\n (click)=\"openLLMModal(llmAction.SUMMARY)\"\r\n >\r\n {{ \"LLM.SUMMARY\" | translate }}\r\n </button>\r\n </div>\r\n\r\n <div [matTooltipPosition]=\"'left'\" [matTooltip]=\"!isTargetLanguageRephrasable ? ('LLM.MENU_REPHRASE_DISABLED_TOOLTIP' | translate) : ''\">\r\n <button\r\n mat-menu-item\r\n [disabled]=\"!isTargetLanguageRephrasable\"\r\n (click)=\"openLLMModal(llmAction.REPHRASE)\"\r\n >\r\n {{ \"LLM.REPHRASE\" | translate }}\r\n </button>\r\n </div>\r\n</mat-menu>\r\n", styles: [""], dependencies: [{ kind: "component", type: i4.MatIconButton, selector: "button[mat-icon-button]", inputs: ["disabled", "disableRipple", "color"], exportAs: ["matButton"] }, { kind: "component", type: i1.MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }, { kind: "component", type: i5.MatMenu, selector: "mat-menu", exportAs: ["matMenu"] }, { kind: "component", type: i5.MatMenuItem, selector: "[mat-menu-item]", inputs: ["disabled", "disableRipple", "role"], exportAs: ["matMenuItem"] }, { kind: "directive", type: i5.MatMenuTrigger, selector: "[mat-menu-trigger-for], [matMenuTriggerFor]", exportAs: ["matMenuTrigger"] }, { kind: "directive", type: i2$1.MatTooltip, selector: "[matTooltip]", exportAs: ["matTooltip"] }, { kind: "pipe", type: i1$1.TranslatePipe, name: "translate" }] }); }
|
|
4735
4736
|
}
|
|
4736
4737
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: LLMComponent, decorators: [{
|
|
4737
4738
|
type: Component,
|
|
4738
|
-
args: [{ selector: 'lib-llm', template: "<button\r\n [disabled]=\"isMenuDisabled\"\r\n [matTooltip]=\"'LLM.MENU_TOOLTIP' | translate\"\r\n mat-icon-button\r\n [matMenuTriggerFor]=\"menu\"\r\n>\r\n <mat-icon svgIcon=\"llm_menu\"></mat-icon>\r\n</button>\r\n\r\n<mat-menu #menu=\"matMenu\">\r\n <div [matTooltip]=\"!isTextSummarizable ? ('LLM.MENU_SUMMARY_DISABLED_TOOLTIP' | translate) : ''\">\r\n <button\r\n mat-menu-item\r\n [disabled]=\"!isTextSummarizable\"\r\n (click)=\"openLLMModal(llmAction.SUMMARY)\"\r\n >\r\n {{ \"LLM.SUMMARY\" | translate }}\r\n </button>\r\n </div>\r\n\r\n <div [matTooltip]=\"!isTargetLanguageRephrasable ? ('LLM.MENU_REPHRASE_DISABLED_TOOLTIP' | translate) : ''\">\r\n <button\r\n mat-menu-item\r\n [disabled]=\"!isTargetLanguageRephrasable\"\r\n (click)=\"openLLMModal(llmAction.REPHRASE)\"\r\n >\r\n {{ \"LLM.REPHRASE\" | translate }}\r\n </button>\r\n </div>\r\n</mat-menu>\r\n" }]
|
|
4739
|
+
args: [{ selector: 'lib-llm', template: "<button\r\n [disabled]=\"isMenuDisabled\"\r\n [matTooltip]=\"'LLM.MENU_TOOLTIP' | translate\"\r\n mat-icon-button\r\n [matMenuTriggerFor]=\"menu\"\r\n>\r\n <mat-icon svgIcon=\"llm_menu\"></mat-icon>\r\n</button>\r\n\r\n<mat-menu #menu=\"matMenu\">\r\n <div [matTooltipPosition]=\"'left'\" [matTooltip]=\"!isTextSummarizable ? ('LLM.MENU_SUMMARY_DISABLED_TOOLTIP' | translate) : ''\">\r\n <button\r\n mat-menu-item\r\n [disabled]=\"!isTextSummarizable\"\r\n (click)=\"openLLMModal(llmAction.SUMMARY)\"\r\n >\r\n {{ \"LLM.SUMMARY\" | translate }}\r\n </button>\r\n </div>\r\n\r\n <div [matTooltipPosition]=\"'left'\" [matTooltip]=\"!isTargetLanguageRephrasable ? ('LLM.MENU_REPHRASE_DISABLED_TOOLTIP' | translate) : ''\">\r\n <button\r\n mat-menu-item\r\n [disabled]=\"!isTargetLanguageRephrasable\"\r\n (click)=\"openLLMModal(llmAction.REPHRASE)\"\r\n >\r\n {{ \"LLM.REPHRASE\" | translate }}\r\n </button>\r\n </div>\r\n</mat-menu>\r\n" }]
|
|
4739
4740
|
}], ctorParameters: function () { return [{ type: i1$3.MatDialog }, { type: IconService }, { type: LanguageTranslateService }]; }, propDecorators: { text: [{
|
|
4740
4741
|
type: Input
|
|
4741
4742
|
}], language: [{
|