@progress/kendo-angular-tooltip 3.1.7-dev.202203090915 → 4.0.0-dev.202204191143
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/bundles/kendo-angular-tooltip.umd.js +5 -0
- package/{dist/es/constants.d.ts → constants.d.ts} +0 -0
- package/{dist/es2015 → esm2015}/constants.js +0 -0
- package/{dist/es/models/functions.model.js → esm2015/kendo-angular-tooltip.js} +4 -0
- package/esm2015/localization/localized-messages.directive.js +38 -0
- package/{dist/es → esm2015}/main.js +2 -0
- package/{dist/es2015 → esm2015}/models/animation.model.js +1 -0
- package/{dist/es2015 → esm2015}/models/events.js +0 -0
- package/{dist/es2015 → esm2015}/models/functions.model.js +1 -0
- package/{dist/es → esm2015}/models/popover-show-option.type.js +1 -0
- package/{dist/es2015 → esm2015}/models/position.type.js +1 -0
- package/{dist/es → esm2015}/models/show.option.type.js +1 -0
- package/{dist/es2015 → esm2015}/package-metadata.js +1 -1
- package/{dist/es2015 → esm2015}/popover/anchor.directive.js +22 -19
- package/{dist/es2015 → esm2015}/popover/container.directive.js +24 -23
- package/{dist/es2015 → esm2015}/popover/directives-base.js +13 -12
- package/{dist/es2015 → esm2015}/popover/popover.component.js +118 -108
- package/{dist/es2015 → esm2015}/popover/popover.service.js +9 -9
- package/esm2015/popover/template-directives/actions-template.directive.js +27 -0
- package/esm2015/popover/template-directives/body-template.directive.js +27 -0
- package/esm2015/popover/template-directives/title-template.directive.js +27 -0
- package/{dist/es2015 → esm2015}/popover.module.js +31 -16
- package/{dist/es2015 → esm2015}/tooltip/tooltip.content.component.js +95 -73
- package/{dist/es2015 → esm2015}/tooltip/tooltip.directive.js +57 -80
- package/{dist/es2015 → esm2015}/tooltip/tooltip.settings.js +12 -7
- package/{dist/es2015 → esm2015}/tooltip.module.js +15 -12
- package/{dist/es2015 → esm2015}/tooltips.module.js +12 -9
- package/{dist/es2015 → esm2015}/utils.js +0 -1
- package/{dist/fesm2015/index.js → fesm2015/kendo-angular-tooltip.js} +456 -399
- package/{dist/es2015/constants.d.ts → kendo-angular-tooltip.d.ts} +3 -6
- package/{dist/es2015/localization → localization}/localized-messages.directive.d.ts +3 -0
- package/{dist/es/main.d.ts → main.d.ts} +3 -0
- package/{dist/es/models → models}/animation.model.d.ts +0 -0
- package/{dist/es/models → models}/events.d.ts +0 -0
- package/{dist/es/models → models}/functions.model.d.ts +0 -0
- package/{dist/es/models → models}/popover-show-option.type.d.ts +0 -0
- package/{dist/es/models → models}/position.type.d.ts +0 -0
- package/{dist/es/models → models}/show.option.type.d.ts +0 -0
- package/{dist/es/package-metadata.d.ts → package-metadata.d.ts} +0 -0
- package/package.json +30 -111
- package/{dist/es2015/popover → popover}/anchor.directive.d.ts +3 -0
- package/{dist/es/popover → popover}/container.directive.d.ts +3 -0
- package/{dist/es2015/popover → popover}/directives-base.d.ts +9 -4
- package/{dist/es2015/popover → popover}/popover.component.d.ts +21 -8
- package/{dist/es/popover → popover}/popover.service.d.ts +7 -4
- package/{dist/es2015/popover → popover}/template-directives/actions-template.directive.d.ts +3 -0
- package/{dist/es2015/popover → popover}/template-directives/body-template.directive.d.ts +3 -0
- package/{dist/es2015/popover → popover}/template-directives/title-template.directive.d.ts +3 -0
- package/popover.module.d.ts +43 -0
- package/schematics/ngAdd/index.js +5 -2
- package/schematics/ngAdd/index.js.map +1 -1
- package/{dist/es/tooltip → tooltip}/tooltip.content.component.d.ts +7 -4
- package/{dist/es/tooltip → tooltip}/tooltip.directive.d.ts +5 -1
- package/{dist/es/tooltip → tooltip}/tooltip.settings.d.ts +7 -0
- package/{dist/es2015/tooltip.module.d.ts → tooltip.module.d.ts} +9 -0
- package/{dist/es2015/tooltips.module.d.ts → tooltips.module.d.ts} +6 -0
- package/{dist/es/utils.d.ts → utils.d.ts} +0 -0
- package/dist/cdn/js/kendo-angular-tooltip.js +0 -20
- package/dist/cdn/main.js +0 -5
- package/dist/es/constants.js +0 -12
- package/dist/es/index.d.ts +0 -12
- package/dist/es/index.js +0 -12
- package/dist/es/index.metadata.json +0 -1
- package/dist/es/localization/localized-messages.directive.d.ts +0 -16
- package/dist/es/localization/localized-messages.directive.js +0 -38
- package/dist/es/models/animation.model.js +0 -4
- package/dist/es/models/events.js +0 -78
- package/dist/es/models/position.type.js +0 -4
- package/dist/es/package-metadata.js +0 -15
- package/dist/es/popover/anchor.directive.d.ts +0 -44
- package/dist/es/popover/anchor.directive.js +0 -156
- package/dist/es/popover/container.directive.js +0 -182
- package/dist/es/popover/directives-base.d.ts +0 -90
- package/dist/es/popover/directives-base.js +0 -294
- package/dist/es/popover/popover.component.d.ts +0 -166
- package/dist/es/popover/popover.component.js +0 -300
- package/dist/es/popover/popover.service.js +0 -88
- package/dist/es/popover/template-directives/actions-template.directive.d.ts +0 -15
- package/dist/es/popover/template-directives/actions-template.directive.js +0 -26
- package/dist/es/popover/template-directives/body-template.directive.d.ts +0 -15
- package/dist/es/popover/template-directives/body-template.directive.js +0 -26
- package/dist/es/popover/template-directives/title-template.directive.d.ts +0 -15
- package/dist/es/popover/template-directives/title-template.directive.js +0 -26
- package/dist/es/popover.module.d.ts +0 -31
- package/dist/es/popover.module.js +0 -65
- package/dist/es/tooltip/tooltip.content.component.js +0 -192
- package/dist/es/tooltip/tooltip.directive.js +0 -452
- package/dist/es/tooltip/tooltip.settings.js +0 -46
- package/dist/es/tooltip.module.d.ts +0 -36
- package/dist/es/tooltip.module.js +0 -57
- package/dist/es/tooltips.module.d.ts +0 -32
- package/dist/es/tooltips.module.js +0 -45
- package/dist/es/utils.js +0 -113
- package/dist/es2015/index.d.ts +0 -12
- package/dist/es2015/index.js +0 -12
- package/dist/es2015/index.metadata.json +0 -1
- package/dist/es2015/localization/localized-messages.directive.js +0 -34
- package/dist/es2015/main.d.ts +0 -22
- package/dist/es2015/main.js +0 -18
- package/dist/es2015/models/animation.model.d.ts +0 -9
- package/dist/es2015/models/events.d.ts +0 -78
- package/dist/es2015/models/functions.model.d.ts +0 -17
- package/dist/es2015/models/popover-show-option.type.d.ts +0 -8
- package/dist/es2015/models/popover-show-option.type.js +0 -4
- package/dist/es2015/models/position.type.d.ts +0 -14
- package/dist/es2015/models/show.option.type.d.ts +0 -13
- package/dist/es2015/models/show.option.type.js +0 -4
- package/dist/es2015/package-metadata.d.ts +0 -9
- package/dist/es2015/popover/container.directive.d.ts +0 -56
- package/dist/es2015/popover/popover.service.d.ts +0 -30
- package/dist/es2015/popover/template-directives/actions-template.directive.js +0 -25
- package/dist/es2015/popover/template-directives/body-template.directive.js +0 -25
- package/dist/es2015/popover/template-directives/title-template.directive.js +0 -25
- package/dist/es2015/popover.module.d.ts +0 -31
- package/dist/es2015/tooltip/tooltip.content.component.d.ts +0 -41
- package/dist/es2015/tooltip/tooltip.directive.d.ts +0 -156
- package/dist/es2015/tooltip/tooltip.settings.d.ts +0 -72
- package/dist/es2015/utils.d.ts +0 -34
- package/dist/fesm5/index.js +0 -2071
- package/dist/npm/constants.js +0 -14
- package/dist/npm/index.js +0 -19
- package/dist/npm/localization/localized-messages.directive.js +0 -40
- package/dist/npm/main.js +0 -36
- package/dist/npm/models/animation.model.js +0 -6
- package/dist/npm/models/events.js +0 -80
- package/dist/npm/models/functions.model.js +0 -6
- package/dist/npm/models/popover-show-option.type.js +0 -6
- package/dist/npm/models/position.type.js +0 -6
- package/dist/npm/models/show.option.type.js +0 -6
- package/dist/npm/package-metadata.js +0 -17
- package/dist/npm/popover/anchor.directive.js +0 -158
- package/dist/npm/popover/container.directive.js +0 -184
- package/dist/npm/popover/directives-base.js +0 -296
- package/dist/npm/popover/popover.component.js +0 -302
- package/dist/npm/popover/popover.service.js +0 -90
- package/dist/npm/popover/template-directives/actions-template.directive.js +0 -28
- package/dist/npm/popover/template-directives/body-template.directive.js +0 -28
- package/dist/npm/popover/template-directives/title-template.directive.js +0 -28
- package/dist/npm/popover.module.js +0 -67
- package/dist/npm/tooltip/tooltip.content.component.js +0 -194
- package/dist/npm/tooltip/tooltip.directive.js +0 -454
- package/dist/npm/tooltip/tooltip.settings.js +0 -48
- package/dist/npm/tooltip.module.js +0 -59
- package/dist/npm/tooltips.module.js +0 -47
- package/dist/npm/utils.js +0 -121
- package/dist/systemjs/kendo-angular-tooltip.js +0 -5
|
@@ -2,7 +2,6 @@
|
|
|
2
2
|
* Copyright © 2021 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 * as tslib_1 from "tslib";
|
|
6
5
|
import { Component, ContentChild, EventEmitter, HostBinding, Input, isDevMode, Output } from '@angular/core';
|
|
7
6
|
import { LocalizationService, L10N_PREFIX } from '@progress/kendo-angular-l10n';
|
|
8
7
|
import { Subscription } from 'rxjs';
|
|
@@ -12,6 +11,9 @@ import { ERRORS } from '../constants';
|
|
|
12
11
|
import { PopoverTitleTemplateDirective } from './template-directives/title-template.directive';
|
|
13
12
|
import { PopoverBodyTemplateDirective } from './template-directives/body-template.directive';
|
|
14
13
|
import { PopoverActionsTemplateDirective } from './template-directives/actions-template.directive';
|
|
14
|
+
import * as i0 from "@angular/core";
|
|
15
|
+
import * as i1 from "@progress/kendo-angular-l10n";
|
|
16
|
+
import * as i2 from "@angular/common";
|
|
15
17
|
/**
|
|
16
18
|
* Represents the [Kendo UI Popover component for Angular]({% slug overview_popover %}).
|
|
17
19
|
* Used to display additional information that is related to a target element.
|
|
@@ -25,7 +27,7 @@ import { PopoverActionsTemplateDirective } from './template-directives/actions-t
|
|
|
25
27
|
* </kendo-popover>
|
|
26
28
|
* ```
|
|
27
29
|
*/
|
|
28
|
-
|
|
30
|
+
export class PopoverComponent {
|
|
29
31
|
constructor(localization) {
|
|
30
32
|
this.localization = localization;
|
|
31
33
|
/**
|
|
@@ -78,9 +80,15 @@ let PopoverComponent = class PopoverComponent {
|
|
|
78
80
|
* Fires after the Popover has been hidden and the animation has ended. [See example]({% slug events_popover %})
|
|
79
81
|
*/
|
|
80
82
|
this.hidden = new EventEmitter();
|
|
81
|
-
|
|
83
|
+
/**
|
|
84
|
+
* @hidden
|
|
85
|
+
*/
|
|
82
86
|
this._width = 'auto';
|
|
87
|
+
/**
|
|
88
|
+
* @hidden
|
|
89
|
+
*/
|
|
83
90
|
this._height = 'auto';
|
|
91
|
+
this._offset = 6;
|
|
84
92
|
this.subs = new Subscription();
|
|
85
93
|
/**
|
|
86
94
|
* @hidden
|
|
@@ -167,107 +175,59 @@ let PopoverComponent = class PopoverComponent {
|
|
|
167
175
|
default: return { 'k-callout-s': true };
|
|
168
176
|
}
|
|
169
177
|
}
|
|
170
|
-
}
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
]
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
]
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
|
|
212
|
-
|
|
213
|
-
|
|
214
|
-
|
|
215
|
-
|
|
216
|
-
|
|
217
|
-
|
|
218
|
-
|
|
219
|
-
|
|
220
|
-
],
|
|
221
|
-
|
|
222
|
-
|
|
223
|
-
tslib_1.__metadata("design:type", Boolean),
|
|
224
|
-
tslib_1.__metadata("design:paramtypes", [])
|
|
225
|
-
], PopoverComponent.prototype, "isHidden", null);
|
|
226
|
-
tslib_1.__decorate([
|
|
227
|
-
HostBinding('attr.aria-hidden'),
|
|
228
|
-
tslib_1.__metadata("design:type", Boolean),
|
|
229
|
-
tslib_1.__metadata("design:paramtypes", [])
|
|
230
|
-
], PopoverComponent.prototype, "hasAttributeHidden", null);
|
|
231
|
-
tslib_1.__decorate([
|
|
232
|
-
Output(),
|
|
233
|
-
tslib_1.__metadata("design:type", EventEmitter)
|
|
234
|
-
], PopoverComponent.prototype, "show", void 0);
|
|
235
|
-
tslib_1.__decorate([
|
|
236
|
-
Output(),
|
|
237
|
-
tslib_1.__metadata("design:type", EventEmitter)
|
|
238
|
-
], PopoverComponent.prototype, "shown", void 0);
|
|
239
|
-
tslib_1.__decorate([
|
|
240
|
-
Output(),
|
|
241
|
-
tslib_1.__metadata("design:type", EventEmitter)
|
|
242
|
-
], PopoverComponent.prototype, "hide", void 0);
|
|
243
|
-
tslib_1.__decorate([
|
|
244
|
-
Output(),
|
|
245
|
-
tslib_1.__metadata("design:type", EventEmitter)
|
|
246
|
-
], PopoverComponent.prototype, "hidden", void 0);
|
|
247
|
-
tslib_1.__decorate([
|
|
248
|
-
ContentChild(PopoverTitleTemplateDirective, { static: false }),
|
|
249
|
-
tslib_1.__metadata("design:type", PopoverTitleTemplateDirective)
|
|
250
|
-
], PopoverComponent.prototype, "titleTemplate", void 0);
|
|
251
|
-
tslib_1.__decorate([
|
|
252
|
-
ContentChild(PopoverBodyTemplateDirective, { static: false }),
|
|
253
|
-
tslib_1.__metadata("design:type", PopoverBodyTemplateDirective)
|
|
254
|
-
], PopoverComponent.prototype, "bodyTemplate", void 0);
|
|
255
|
-
tslib_1.__decorate([
|
|
256
|
-
ContentChild(PopoverActionsTemplateDirective, { static: false }),
|
|
257
|
-
tslib_1.__metadata("design:type", PopoverActionsTemplateDirective)
|
|
258
|
-
], PopoverComponent.prototype, "actionsTemplate", void 0);
|
|
259
|
-
PopoverComponent = tslib_1.__decorate([
|
|
260
|
-
Component({
|
|
261
|
-
selector: 'kendo-popover',
|
|
262
|
-
providers: [
|
|
263
|
-
LocalizationService,
|
|
264
|
-
{
|
|
265
|
-
provide: L10N_PREFIX,
|
|
266
|
-
useValue: 'kendo.popover'
|
|
267
|
-
}
|
|
268
|
-
],
|
|
269
|
-
template: `
|
|
270
|
-
<div *ngIf="visible" role="tooltip" class="k-popover" [ngStyle]="{'width.px': width, 'height.px': height}">
|
|
178
|
+
}
|
|
179
|
+
PopoverComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: PopoverComponent, deps: [{ token: i1.LocalizationService }], target: i0.ɵɵFactoryTarget.Component });
|
|
180
|
+
PopoverComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.16", type: PopoverComponent, selector: "kendo-popover", inputs: { position: "position", offset: "offset", width: "width", height: "height", title: "title", subtitle: "subtitle", body: "body", callout: "callout", animation: "animation", templateData: "templateData" }, outputs: { show: "show", shown: "shown", hide: "hide", hidden: "hidden" }, host: { properties: { "attr.dir": "this.direction", "class.k-hidden": "this.isHidden", "attr.aria-hidden": "this.hasAttributeHidden", "style.width": "this._width", "style.height": "this._height" } }, providers: [
|
|
181
|
+
LocalizationService,
|
|
182
|
+
{
|
|
183
|
+
provide: L10N_PREFIX,
|
|
184
|
+
useValue: 'kendo.popover'
|
|
185
|
+
}
|
|
186
|
+
], queries: [{ propertyName: "titleTemplate", first: true, predicate: PopoverTitleTemplateDirective, descendants: true }, { propertyName: "bodyTemplate", first: true, predicate: PopoverBodyTemplateDirective, descendants: true }, { propertyName: "actionsTemplate", first: true, predicate: PopoverActionsTemplateDirective, descendants: true }], ngImport: i0, template: `
|
|
187
|
+
<div *ngIf="visible" role="tooltip" class="k-popover" [ngStyle]="{'width': width, 'height': height}">
|
|
188
|
+
<div class="k-popover-callout" [ngClass]="getCalloutPosition()" *ngIf="callout"></div>
|
|
189
|
+
|
|
190
|
+
<div *ngIf="titleTemplate || title" class="k-popover-header">
|
|
191
|
+
<ng-template *ngIf="titleTemplate"
|
|
192
|
+
[ngTemplateOutlet]="titleTemplate?.templateRef"
|
|
193
|
+
[ngTemplateOutletContext]="{ $implicit: anchor, data: contextData }">
|
|
194
|
+
</ng-template>
|
|
195
|
+
<ng-container *ngIf="title && !titleTemplate">
|
|
196
|
+
{{ title }}
|
|
197
|
+
</ng-container>
|
|
198
|
+
</div>
|
|
199
|
+
|
|
200
|
+
<div *ngIf="bodyTemplate || body" class="k-popover-body">
|
|
201
|
+
<ng-template *ngIf="bodyTemplate"
|
|
202
|
+
[ngTemplateOutlet]="bodyTemplate?.templateRef"
|
|
203
|
+
[ngTemplateOutletContext]="{ $implicit: anchor, data: contextData }">
|
|
204
|
+
</ng-template>
|
|
205
|
+
<ng-container *ngIf="body && !bodyTemplate">
|
|
206
|
+
{{ body }}
|
|
207
|
+
</ng-container>
|
|
208
|
+
</div>
|
|
209
|
+
|
|
210
|
+
<div *ngIf="actionsTemplate" class="k-popover-actions k-actions k-hstack k-justify-content-between">
|
|
211
|
+
<ng-template *ngIf="actionsTemplate"
|
|
212
|
+
[ngTemplateOutlet]="actionsTemplate?.templateRef"
|
|
213
|
+
[ngTemplateOutletContext]="{ $implicit: anchor, data: contextData }">
|
|
214
|
+
</ng-template>
|
|
215
|
+
</div>
|
|
216
|
+
</div>
|
|
217
|
+
`, isInline: true, directives: [{ type: i2.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i2.NgStyle, selector: "[ngStyle]", inputs: ["ngStyle"] }, { type: i2.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { type: i2.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet"] }] });
|
|
218
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: PopoverComponent, decorators: [{
|
|
219
|
+
type: Component,
|
|
220
|
+
args: [{
|
|
221
|
+
selector: 'kendo-popover',
|
|
222
|
+
providers: [
|
|
223
|
+
LocalizationService,
|
|
224
|
+
{
|
|
225
|
+
provide: L10N_PREFIX,
|
|
226
|
+
useValue: 'kendo.popover'
|
|
227
|
+
}
|
|
228
|
+
],
|
|
229
|
+
template: `
|
|
230
|
+
<div *ngIf="visible" role="tooltip" class="k-popover" [ngStyle]="{'width': width, 'height': height}">
|
|
271
231
|
<div class="k-popover-callout" [ngClass]="getCalloutPosition()" *ngIf="callout"></div>
|
|
272
232
|
|
|
273
233
|
<div *ngIf="titleTemplate || title" class="k-popover-header">
|
|
@@ -298,7 +258,57 @@ PopoverComponent = tslib_1.__decorate([
|
|
|
298
258
|
</div>
|
|
299
259
|
</div>
|
|
300
260
|
`
|
|
301
|
-
|
|
302
|
-
|
|
303
|
-
|
|
304
|
-
|
|
261
|
+
}]
|
|
262
|
+
}], ctorParameters: function () { return [{ type: i1.LocalizationService }]; }, propDecorators: { position: [{
|
|
263
|
+
type: Input
|
|
264
|
+
}], offset: [{
|
|
265
|
+
type: Input
|
|
266
|
+
}], width: [{
|
|
267
|
+
type: Input
|
|
268
|
+
}], height: [{
|
|
269
|
+
type: Input
|
|
270
|
+
}], direction: [{
|
|
271
|
+
type: HostBinding,
|
|
272
|
+
args: ['attr.dir']
|
|
273
|
+
}], title: [{
|
|
274
|
+
type: Input
|
|
275
|
+
}], subtitle: [{
|
|
276
|
+
type: Input
|
|
277
|
+
}], body: [{
|
|
278
|
+
type: Input
|
|
279
|
+
}], callout: [{
|
|
280
|
+
type: Input
|
|
281
|
+
}], animation: [{
|
|
282
|
+
type: Input
|
|
283
|
+
}], templateData: [{
|
|
284
|
+
type: Input
|
|
285
|
+
}], isHidden: [{
|
|
286
|
+
type: HostBinding,
|
|
287
|
+
args: ['class.k-hidden']
|
|
288
|
+
}], hasAttributeHidden: [{
|
|
289
|
+
type: HostBinding,
|
|
290
|
+
args: ['attr.aria-hidden']
|
|
291
|
+
}], show: [{
|
|
292
|
+
type: Output
|
|
293
|
+
}], shown: [{
|
|
294
|
+
type: Output
|
|
295
|
+
}], hide: [{
|
|
296
|
+
type: Output
|
|
297
|
+
}], hidden: [{
|
|
298
|
+
type: Output
|
|
299
|
+
}], titleTemplate: [{
|
|
300
|
+
type: ContentChild,
|
|
301
|
+
args: [PopoverTitleTemplateDirective, { static: false }]
|
|
302
|
+
}], bodyTemplate: [{
|
|
303
|
+
type: ContentChild,
|
|
304
|
+
args: [PopoverBodyTemplateDirective, { static: false }]
|
|
305
|
+
}], actionsTemplate: [{
|
|
306
|
+
type: ContentChild,
|
|
307
|
+
args: [PopoverActionsTemplateDirective, { static: false }]
|
|
308
|
+
}], _width: [{
|
|
309
|
+
type: HostBinding,
|
|
310
|
+
args: ['style.width']
|
|
311
|
+
}], _height: [{
|
|
312
|
+
type: HostBinding,
|
|
313
|
+
args: ['style.height']
|
|
314
|
+
}] } });
|
|
@@ -2,14 +2,14 @@
|
|
|
2
2
|
* Copyright © 2021 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
|
|
6
|
-
import { Injectable, NgZone } from '@angular/core';
|
|
5
|
+
import { Injectable } from '@angular/core';
|
|
7
6
|
import { BehaviorSubject, combineLatest, Subject, Subscription } from 'rxjs';
|
|
8
7
|
import { auditTime } from 'rxjs/operators';
|
|
8
|
+
import * as i0 from "@angular/core";
|
|
9
9
|
/**
|
|
10
10
|
* @hidden
|
|
11
11
|
*/
|
|
12
|
-
|
|
12
|
+
export class PopoverService {
|
|
13
13
|
constructor(ngZone) {
|
|
14
14
|
this.ngZone = ngZone;
|
|
15
15
|
this._pointerOverPopup = new BehaviorSubject(null);
|
|
@@ -59,9 +59,9 @@ let PopoverService = class PopoverService {
|
|
|
59
59
|
this._hidePopover.next([isPopoverHovered, isAnchorHovered, this._isOrigin, this.currentAnchor]);
|
|
60
60
|
}));
|
|
61
61
|
}
|
|
62
|
-
}
|
|
63
|
-
PopoverService =
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
62
|
+
}
|
|
63
|
+
PopoverService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: PopoverService, deps: [{ token: i0.NgZone }], target: i0.ɵɵFactoryTarget.Injectable });
|
|
64
|
+
PopoverService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: PopoverService });
|
|
65
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: PopoverService, decorators: [{
|
|
66
|
+
type: Injectable
|
|
67
|
+
}], ctorParameters: function () { return [{ type: i0.NgZone }]; } });
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
/**-----------------------------------------------------------------------------------------
|
|
2
|
+
* Copyright © 2021 Progress Software Corporation. All rights reserved.
|
|
3
|
+
* Licensed under commercial license. See LICENSE.md in the project root for more information
|
|
4
|
+
*-------------------------------------------------------------------------------------------*/
|
|
5
|
+
import { Directive, Optional } from '@angular/core';
|
|
6
|
+
import * as i0 from "@angular/core";
|
|
7
|
+
/**
|
|
8
|
+
* Represents a template that defines the content of the Popover actions.
|
|
9
|
+
*
|
|
10
|
+
* To define the template, nest an `<ng-template>` tag
|
|
11
|
+
* with the `kendoPopoverActionsTemplate` directive inside the `<kendo-popover>` tag.
|
|
12
|
+
*/
|
|
13
|
+
export class PopoverActionsTemplateDirective {
|
|
14
|
+
constructor(templateRef) {
|
|
15
|
+
this.templateRef = templateRef;
|
|
16
|
+
}
|
|
17
|
+
}
|
|
18
|
+
PopoverActionsTemplateDirective.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: PopoverActionsTemplateDirective, deps: [{ token: i0.TemplateRef, optional: true }], target: i0.ɵɵFactoryTarget.Directive });
|
|
19
|
+
PopoverActionsTemplateDirective.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "12.0.0", version: "12.2.16", type: PopoverActionsTemplateDirective, selector: "[kendoPopoverActionsTemplate]", ngImport: i0 });
|
|
20
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: PopoverActionsTemplateDirective, decorators: [{
|
|
21
|
+
type: Directive,
|
|
22
|
+
args: [{
|
|
23
|
+
selector: '[kendoPopoverActionsTemplate]'
|
|
24
|
+
}]
|
|
25
|
+
}], ctorParameters: function () { return [{ type: i0.TemplateRef, decorators: [{
|
|
26
|
+
type: Optional
|
|
27
|
+
}] }]; } });
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
/**-----------------------------------------------------------------------------------------
|
|
2
|
+
* Copyright © 2021 Progress Software Corporation. All rights reserved.
|
|
3
|
+
* Licensed under commercial license. See LICENSE.md in the project root for more information
|
|
4
|
+
*-------------------------------------------------------------------------------------------*/
|
|
5
|
+
import { Directive, Optional } from '@angular/core';
|
|
6
|
+
import * as i0 from "@angular/core";
|
|
7
|
+
/**
|
|
8
|
+
* Represents a template that defines the content of the Popover body.
|
|
9
|
+
*
|
|
10
|
+
* To define the template, nest an `<ng-template>` tag
|
|
11
|
+
* with the `kendoPopoverBodyTemplate` directive inside the `<kendo-popover>` tag.
|
|
12
|
+
*/
|
|
13
|
+
export class PopoverBodyTemplateDirective {
|
|
14
|
+
constructor(templateRef) {
|
|
15
|
+
this.templateRef = templateRef;
|
|
16
|
+
}
|
|
17
|
+
}
|
|
18
|
+
PopoverBodyTemplateDirective.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: PopoverBodyTemplateDirective, deps: [{ token: i0.TemplateRef, optional: true }], target: i0.ɵɵFactoryTarget.Directive });
|
|
19
|
+
PopoverBodyTemplateDirective.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "12.0.0", version: "12.2.16", type: PopoverBodyTemplateDirective, selector: "[kendoPopoverBodyTemplate]", ngImport: i0 });
|
|
20
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: PopoverBodyTemplateDirective, decorators: [{
|
|
21
|
+
type: Directive,
|
|
22
|
+
args: [{
|
|
23
|
+
selector: '[kendoPopoverBodyTemplate]'
|
|
24
|
+
}]
|
|
25
|
+
}], ctorParameters: function () { return [{ type: i0.TemplateRef, decorators: [{
|
|
26
|
+
type: Optional
|
|
27
|
+
}] }]; } });
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
/**-----------------------------------------------------------------------------------------
|
|
2
|
+
* Copyright © 2021 Progress Software Corporation. All rights reserved.
|
|
3
|
+
* Licensed under commercial license. See LICENSE.md in the project root for more information
|
|
4
|
+
*-------------------------------------------------------------------------------------------*/
|
|
5
|
+
import { Directive, Optional } from '@angular/core';
|
|
6
|
+
import * as i0 from "@angular/core";
|
|
7
|
+
/**
|
|
8
|
+
* Represents a template that defines the content of the Popover title.
|
|
9
|
+
*
|
|
10
|
+
* To define the template, nest an `<ng-template>` tag
|
|
11
|
+
* with the `kendoPopoverTitleTemplate` directive inside the `<kendo-popover>` tag.
|
|
12
|
+
*/
|
|
13
|
+
export class PopoverTitleTemplateDirective {
|
|
14
|
+
constructor(templateRef) {
|
|
15
|
+
this.templateRef = templateRef;
|
|
16
|
+
}
|
|
17
|
+
}
|
|
18
|
+
PopoverTitleTemplateDirective.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: PopoverTitleTemplateDirective, deps: [{ token: i0.TemplateRef, optional: true }], target: i0.ɵɵFactoryTarget.Directive });
|
|
19
|
+
PopoverTitleTemplateDirective.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "12.0.0", version: "12.2.16", type: PopoverTitleTemplateDirective, selector: "[kendoPopoverTitleTemplate]", ngImport: i0 });
|
|
20
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: PopoverTitleTemplateDirective, decorators: [{
|
|
21
|
+
type: Directive,
|
|
22
|
+
args: [{
|
|
23
|
+
selector: '[kendoPopoverTitleTemplate]'
|
|
24
|
+
}]
|
|
25
|
+
}], ctorParameters: function () { return [{ type: i0.TemplateRef, decorators: [{
|
|
26
|
+
type: Optional
|
|
27
|
+
}] }]; } });
|
|
@@ -2,7 +2,6 @@
|
|
|
2
2
|
* Copyright © 2021 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 * as tslib_1 from "tslib";
|
|
6
5
|
import { CommonModule } from "@angular/common";
|
|
7
6
|
import { NgModule } from "@angular/core";
|
|
8
7
|
import { PopupModule } from "@progress/kendo-angular-popup";
|
|
@@ -12,6 +11,7 @@ import { PopoverComponent } from "./popover/popover.component";
|
|
|
12
11
|
import { PopoverTitleTemplateDirective } from './popover/template-directives/title-template.directive';
|
|
13
12
|
import { PopoverBodyTemplateDirective } from './popover/template-directives/body-template.directive';
|
|
14
13
|
import { PopoverActionsTemplateDirective } from './popover/template-directives/actions-template.directive';
|
|
14
|
+
import * as i0 from "@angular/core";
|
|
15
15
|
const DIRECTIVES = [
|
|
16
16
|
PopoverActionsTemplateDirective,
|
|
17
17
|
PopoverBodyTemplateDirective,
|
|
@@ -44,20 +44,35 @@ const DIRECTIVES = [
|
|
|
44
44
|
*
|
|
45
45
|
* ```
|
|
46
46
|
*/
|
|
47
|
-
|
|
48
|
-
}
|
|
49
|
-
PopoverModule =
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
],
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
47
|
+
export class PopoverModule {
|
|
48
|
+
}
|
|
49
|
+
PopoverModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: PopoverModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
|
|
50
|
+
PopoverModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: PopoverModule, declarations: [PopoverActionsTemplateDirective,
|
|
51
|
+
PopoverBodyTemplateDirective,
|
|
52
|
+
PopoverTitleTemplateDirective,
|
|
53
|
+
PopoverAnchorDirective,
|
|
54
|
+
PopoverContainerDirective, PopoverComponent], imports: [CommonModule,
|
|
55
|
+
PopupModule], exports: [PopoverActionsTemplateDirective,
|
|
56
|
+
PopoverBodyTemplateDirective,
|
|
57
|
+
PopoverTitleTemplateDirective,
|
|
58
|
+
PopoverAnchorDirective,
|
|
59
|
+
PopoverContainerDirective, PopoverComponent] });
|
|
60
|
+
PopoverModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: PopoverModule, imports: [[
|
|
58
61
|
CommonModule,
|
|
59
62
|
PopupModule
|
|
60
|
-
]
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
63
|
+
]] });
|
|
64
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: PopoverModule, decorators: [{
|
|
65
|
+
type: NgModule,
|
|
66
|
+
args: [{
|
|
67
|
+
declarations: [
|
|
68
|
+
...DIRECTIVES,
|
|
69
|
+
PopoverComponent
|
|
70
|
+
],
|
|
71
|
+
entryComponents: [PopoverComponent],
|
|
72
|
+
exports: [...DIRECTIVES, PopoverComponent],
|
|
73
|
+
imports: [
|
|
74
|
+
CommonModule,
|
|
75
|
+
PopupModule
|
|
76
|
+
]
|
|
77
|
+
}]
|
|
78
|
+
}] });
|
|
@@ -2,14 +2,17 @@
|
|
|
2
2
|
* Copyright © 2021 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
|
|
6
|
-
import { Component, HostBinding, Input, ElementRef, TemplateRef, Output, EventEmitter } from '@angular/core';
|
|
5
|
+
import { Component, HostBinding, Input, Output, EventEmitter } from '@angular/core';
|
|
7
6
|
import { LocalizationService, L10N_PREFIX } from '@progress/kendo-angular-l10n';
|
|
8
7
|
import { getCenterOffset } from '../utils';
|
|
8
|
+
import * as i0 from "@angular/core";
|
|
9
|
+
import * as i1 from "@progress/kendo-angular-l10n";
|
|
10
|
+
import * as i2 from "../localization/localized-messages.directive";
|
|
11
|
+
import * as i3 from "@angular/common";
|
|
9
12
|
/**
|
|
10
13
|
* @hidden
|
|
11
14
|
*/
|
|
12
|
-
|
|
15
|
+
export class TooltipContentComponent {
|
|
13
16
|
constructor(content, localizationService) {
|
|
14
17
|
this.content = content;
|
|
15
18
|
this.localizationService = localizationService;
|
|
@@ -99,64 +102,52 @@ let TooltipContentComponent = class TooltipContentComponent {
|
|
|
99
102
|
callout.style[style] = calloutStyles[style];
|
|
100
103
|
});
|
|
101
104
|
}
|
|
102
|
-
}
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
],
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
]
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
tslib_1.__decorate([
|
|
149
|
-
Input(),
|
|
150
|
-
tslib_1.__metadata("design:type", TemplateRef)
|
|
151
|
-
], TooltipContentComponent.prototype, "templateRef", void 0);
|
|
152
|
-
tslib_1.__decorate([
|
|
153
|
-
Input(),
|
|
154
|
-
tslib_1.__metadata("design:type", String)
|
|
155
|
-
], TooltipContentComponent.prototype, "templateString", void 0);
|
|
156
|
-
TooltipContentComponent = tslib_1.__decorate([
|
|
157
|
-
Component({
|
|
158
|
-
selector: 'kendo-tooltip',
|
|
159
|
-
template: `
|
|
105
|
+
}
|
|
106
|
+
TooltipContentComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: TooltipContentComponent, deps: [{ token: i0.ElementRef }, { token: i1.LocalizationService }], target: i0.ɵɵFactoryTarget.Component });
|
|
107
|
+
TooltipContentComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.16", type: TooltipContentComponent, selector: "kendo-tooltip", inputs: { tooltipWidth: "tooltipWidth", tooltipHeight: "tooltipHeight", titleTemplate: "titleTemplate", anchor: "anchor", closable: "closable", templateRef: "templateRef", templateString: "templateString" }, outputs: { close: "close" }, host: { properties: { "attr.dir": "this.direction", "class": "this.cssClasses", "class.k-tooltip-closable": "this.className", "style.position": "this.cssPosition", "style.width.px": "this.tooltipWidth", "style.height.px": "this.tooltipHeight" } }, providers: [
|
|
108
|
+
LocalizationService,
|
|
109
|
+
{
|
|
110
|
+
provide: L10N_PREFIX,
|
|
111
|
+
useValue: 'kendo.tooltip'
|
|
112
|
+
}
|
|
113
|
+
], ngImport: i0, template: `
|
|
114
|
+
<ng-container kendoTooltipLocalizedMessages
|
|
115
|
+
i18n-closeTitle="kendo.tooltip.closeTitle|The title of the close button"
|
|
116
|
+
closeTitle="Close"
|
|
117
|
+
>
|
|
118
|
+
</ng-container>
|
|
119
|
+
|
|
120
|
+
<div class="k-tooltip-content">
|
|
121
|
+
<div class="k-tooltip-title" *ngIf="titleTemplate">
|
|
122
|
+
<ng-template
|
|
123
|
+
[ngIf]="titleTemplate"
|
|
124
|
+
[ngTemplateOutlet]="titleTemplate"
|
|
125
|
+
[ngTemplateOutletContext]="{ $implicit: anchor, anchor: anchor }">
|
|
126
|
+
</ng-template>
|
|
127
|
+
</div>
|
|
128
|
+
|
|
129
|
+
<ng-template
|
|
130
|
+
[ngIf]="templateRef"
|
|
131
|
+
[ngTemplateOutlet]="templateRef"
|
|
132
|
+
[ngTemplateOutletContext]="{ $implicit: anchor, anchor: anchor }">
|
|
133
|
+
</ng-template>
|
|
134
|
+
<ng-template
|
|
135
|
+
[ngIf]="templateString">
|
|
136
|
+
{{ templateString }}
|
|
137
|
+
</ng-template>
|
|
138
|
+
</div>
|
|
139
|
+
|
|
140
|
+
<div *ngIf="closable" class="k-tooltip-button" (click)="onCloseClick($event)">
|
|
141
|
+
<a href="#" class="k-icon k-i-close" [attr.title]="closeButtonTitle"></a>
|
|
142
|
+
</div>
|
|
143
|
+
|
|
144
|
+
<div class="k-callout" *ngIf="callout" [ngClass]="calloutPositionClass()"></div>
|
|
145
|
+
`, isInline: true, directives: [{ type: i2.LocalizedMessagesDirective, selector: "[kendoTooltipLocalizedMessages]", inputs: ["closeTitle"] }, { type: i3.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i3.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet"] }, { type: i3.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }] });
|
|
146
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: TooltipContentComponent, decorators: [{
|
|
147
|
+
type: Component,
|
|
148
|
+
args: [{
|
|
149
|
+
selector: 'kendo-tooltip',
|
|
150
|
+
template: `
|
|
160
151
|
<ng-container kendoTooltipLocalizedMessages
|
|
161
152
|
i18n-closeTitle="kendo.tooltip.closeTitle|The title of the close button"
|
|
162
153
|
closeTitle="Close"
|
|
@@ -189,15 +180,46 @@ TooltipContentComponent = tslib_1.__decorate([
|
|
|
189
180
|
|
|
190
181
|
<div class="k-callout" *ngIf="callout" [ngClass]="calloutPositionClass()"></div>
|
|
191
182
|
`,
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
]
|
|
203
|
-
|
|
183
|
+
providers: [
|
|
184
|
+
LocalizationService,
|
|
185
|
+
{
|
|
186
|
+
provide: L10N_PREFIX,
|
|
187
|
+
useValue: 'kendo.tooltip'
|
|
188
|
+
}
|
|
189
|
+
]
|
|
190
|
+
}]
|
|
191
|
+
}], ctorParameters: function () { return [{ type: i0.ElementRef }, { type: i1.LocalizationService }]; }, propDecorators: { direction: [{
|
|
192
|
+
type: HostBinding,
|
|
193
|
+
args: ['attr.dir']
|
|
194
|
+
}], close: [{
|
|
195
|
+
type: Output
|
|
196
|
+
}], cssClasses: [{
|
|
197
|
+
type: HostBinding,
|
|
198
|
+
args: ['class']
|
|
199
|
+
}], className: [{
|
|
200
|
+
type: HostBinding,
|
|
201
|
+
args: ['class.k-tooltip-closable']
|
|
202
|
+
}], cssPosition: [{
|
|
203
|
+
type: HostBinding,
|
|
204
|
+
args: ['style.position']
|
|
205
|
+
}], tooltipWidth: [{
|
|
206
|
+
type: HostBinding,
|
|
207
|
+
args: ['style.width.px']
|
|
208
|
+
}, {
|
|
209
|
+
type: Input
|
|
210
|
+
}], tooltipHeight: [{
|
|
211
|
+
type: HostBinding,
|
|
212
|
+
args: ['style.height.px']
|
|
213
|
+
}, {
|
|
214
|
+
type: Input
|
|
215
|
+
}], titleTemplate: [{
|
|
216
|
+
type: Input
|
|
217
|
+
}], anchor: [{
|
|
218
|
+
type: Input
|
|
219
|
+
}], closable: [{
|
|
220
|
+
type: Input
|
|
221
|
+
}], templateRef: [{
|
|
222
|
+
type: Input
|
|
223
|
+
}], templateString: [{
|
|
224
|
+
type: Input
|
|
225
|
+
}] } });
|