carbon-components-angular 5.59.0 → 5.59.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.
- package/docs/documentation/classes/IconCache.html +1 -1
- package/docs/documentation/classes/IconMemoryCache.html +1 -1
- package/docs/documentation/classes/IconNameNotFoundError.html +1 -1
- package/docs/documentation/classes/IconSizeNotFoundError.html +1 -1
- package/docs/documentation/components/TooltipDefinition.html +176 -38
- package/docs/documentation/coverage.html +3 -3
- package/docs/documentation/injectables/IconService.html +1 -1
- package/docs/documentation/interfaces/IconDescriptor.html +1 -1
- package/docs/documentation/js/search/search_index.js +2 -2
- package/docs/documentation/modules/ThemeModule/dependencies.svg +13 -13
- package/docs/documentation/modules/ThemeModule.html +13 -13
- package/docs/documentation/modules/TilesModule/dependencies.svg +106 -106
- package/docs/documentation/modules/TilesModule.html +106 -106
- package/docs/documentation/modules/TimePickerModule/dependencies.svg +17 -17
- package/docs/documentation/modules/TimePickerModule.html +17 -17
- package/docs/documentation/modules/TimePickerSelectModule/dependencies.svg +30 -30
- package/docs/documentation/modules/TimePickerSelectModule.html +30 -30
- package/docs/documentation/modules/ToggleModule/dependencies.svg +42 -38
- package/docs/documentation/modules/ToggleModule.html +42 -38
- package/docs/documentation/modules/TooltipModule/dependencies.svg +4 -4
- package/docs/documentation/modules/TooltipModule.html +4 -4
- package/docs/documentation/modules/TreeviewModule/dependencies.svg +31 -31
- package/docs/documentation/modules/TreeviewModule.html +31 -31
- package/docs/documentation.json +179 -159
- package/docs/storybook/{1919.baa222c3.iframe.bundle.js → 1919.72ba5983.iframe.bundle.js} +1 -1
- package/docs/storybook/{4292.d48fe81e.iframe.bundle.js → 4292.c9a7a05a.iframe.bundle.js} +1 -1
- package/docs/storybook/{6702.8fcd135f.iframe.bundle.js → 6702.a0e549d4.iframe.bundle.js} +1 -1
- package/docs/storybook/{7141.92a0a90c.iframe.bundle.js → 7141.cd523cae.iframe.bundle.js} +1 -1
- package/docs/storybook/{9672.12e6e85f.iframe.bundle.js → 9672.095adafd.iframe.bundle.js} +1 -1
- package/docs/storybook/{accordion-accordion-stories.1c3982a6.iframe.bundle.js → accordion-accordion-stories.f5bf1512.iframe.bundle.js} +1 -1
- package/docs/storybook/{button-button-set-stories.2257c93f.iframe.bundle.js → button-button-set-stories.6549e188.iframe.bundle.js} +1 -1
- package/docs/storybook/{button-button-stories.1d926b54.iframe.bundle.js → button-button-stories.59023679.iframe.bundle.js} +1 -1
- package/docs/storybook/{button-icon-button-stories.d66c1f0b.iframe.bundle.js → button-icon-button-stories.5d89667b.iframe.bundle.js} +1 -1
- package/docs/storybook/{code-snippet-code-snippet-stories.591d43f5.iframe.bundle.js → code-snippet-code-snippet-stories.efb95808.iframe.bundle.js} +1 -1
- package/docs/storybook/{combobox-combobox-stories.67eec93c.iframe.bundle.js → combobox-combobox-stories.e1951a15.iframe.bundle.js} +1 -1
- package/docs/storybook/{datepicker-datepicker-stories.21d91b98.iframe.bundle.js → datepicker-datepicker-stories.de27eb4c.iframe.bundle.js} +1 -1
- package/docs/storybook/{dropdown-dropdown-stories.97d1c398.iframe.bundle.js → dropdown-dropdown-stories.9e5187d3.iframe.bundle.js} +1 -1
- package/docs/storybook/{icon-icon-stories.03be9c0f.iframe.bundle.js → icon-icon-stories.d69b9d0e.iframe.bundle.js} +1 -1
- package/docs/storybook/iframe.html +2 -2
- package/docs/storybook/{index-stories.164d34c4.iframe.bundle.js → index-stories.18fc437f.iframe.bundle.js} +1 -1
- package/docs/storybook/{inline-loading-inline-loading-stories.8f458636.iframe.bundle.js → inline-loading-inline-loading-stories.ab8e5124.iframe.bundle.js} +1 -1
- package/docs/storybook/{input-input-stories.0acd15ad.iframe.bundle.js → input-input-stories.150d2506.iframe.bundle.js} +1 -1
- package/docs/storybook/{input-password-stories.26988a51.iframe.bundle.js → input-password-stories.f679d74a.iframe.bundle.js} +1 -1
- package/docs/storybook/{input-textarea-stories.44475ab4.iframe.bundle.js → input-textarea-stories.7fb8fce5.iframe.bundle.js} +1 -1
- package/docs/storybook/{link-link-stories.195dfe5f.iframe.bundle.js → link-link-stories.93918572.iframe.bundle.js} +1 -1
- package/docs/storybook/main.762d7fb4.iframe.bundle.js +1 -0
- package/docs/storybook/main.css +2137 -697
- package/docs/storybook/{number-input-number-stories.3196a4f3.iframe.bundle.js → number-input-number-stories.03977301.iframe.bundle.js} +1 -1
- package/docs/storybook/{patterns-loading-large-loading-stories.6f92d3f6.iframe.bundle.js → patterns-loading-large-loading-stories.eddc07f6.iframe.bundle.js} +1 -1
- package/docs/storybook/{progress-bar-progress-bar-stories.ffe95f75.iframe.bundle.js → progress-bar-progress-bar-stories.ed5b1329.iframe.bundle.js} +1 -1
- package/docs/storybook/{progress-indicator-progress-indicator-stories.0b996c97.iframe.bundle.js → progress-indicator-progress-indicator-stories.fcb4b1a5.iframe.bundle.js} +1 -1
- package/docs/storybook/project.json +1 -1
- package/docs/storybook/{radio-radio-stories.fb3fb37b.iframe.bundle.js → radio-radio-stories.6a5c7514.iframe.bundle.js} +1 -1
- package/docs/storybook/{runtime~main.c31464c5.iframe.bundle.js → runtime~main.771b0b54.iframe.bundle.js} +1 -1
- package/docs/storybook/{search-search-stories.f110ce00.iframe.bundle.js → search-search-stories.bb8f4fa0.iframe.bundle.js} +1 -1
- package/docs/storybook/{structured-list-structured-list-stories.42d9b351.iframe.bundle.js → structured-list-structured-list-stories.79fad143.iframe.bundle.js} +1 -1
- package/docs/storybook/{tag-tag-stories.b4426a9b.iframe.bundle.js → tag-tag-stories.26f051fe.iframe.bundle.js} +1 -1
- package/docs/storybook/{tooltip-definition-tooptip-stories.16c9af6d.iframe.bundle.js → tooltip-definition-tooptip-stories.9a2a5436.iframe.bundle.js} +1 -1
- package/docs/storybook/{treeview-treeview-stories.cc4423f1.iframe.bundle.js → treeview-treeview-stories.fefea97f.iframe.bundle.js} +1 -1
- package/docs/storybook/{ui-shell-ui-shell-stories.a7356f0e.iframe.bundle.js → ui-shell-ui-shell-stories.545bbc64.iframe.bundle.js} +1 -1
- package/esm2020/icon/icon.service.mjs +2 -2
- package/esm2020/tooltip/definition-tooptip.component.mjs +26 -7
- package/fesm2015/carbon-components-angular-icon.mjs +1 -1
- package/fesm2015/carbon-components-angular-icon.mjs.map +1 -1
- package/fesm2015/carbon-components-angular-tooltip.mjs +25 -6
- package/fesm2015/carbon-components-angular-tooltip.mjs.map +1 -1
- package/fesm2020/carbon-components-angular-icon.mjs +1 -1
- package/fesm2020/carbon-components-angular-icon.mjs.map +1 -1
- package/fesm2020/carbon-components-angular-tooltip.mjs +25 -6
- package/fesm2020/carbon-components-angular-tooltip.mjs.map +1 -1
- package/package.json +1 -1
- package/tooltip/definition-tooptip.component.d.ts +7 -1
- package/docs/storybook/main.4d0fdfae.iframe.bundle.js +0 -1
|
@@ -222,14 +222,29 @@ class TooltipDefinition extends PopoverContainer {
|
|
|
222
222
|
this.changeDetectorRef = changeDetectorRef;
|
|
223
223
|
this.id = `tooltip-definition-${TooltipDefinition.tooltipCount++}`;
|
|
224
224
|
this.openOnHover = false;
|
|
225
|
+
/**
|
|
226
|
+
* Helper variable to ensure button blur doesn't fire on `click` of popover content
|
|
227
|
+
*/
|
|
228
|
+
this.isInteractingWithPopover = false;
|
|
225
229
|
this.highContrast = true;
|
|
226
230
|
this.dropShadow = false;
|
|
227
231
|
}
|
|
228
232
|
onBlur(event) {
|
|
229
|
-
|
|
233
|
+
// Only close if user is not interacting with popover content
|
|
234
|
+
if (!this.isInteractingWithPopover) {
|
|
235
|
+
this.handleChange(false, event);
|
|
236
|
+
}
|
|
230
237
|
}
|
|
231
238
|
onClick(event) {
|
|
232
|
-
|
|
239
|
+
if (event.button === 0) {
|
|
240
|
+
this.handleChange(!this.isOpen, event);
|
|
241
|
+
}
|
|
242
|
+
}
|
|
243
|
+
onPopoverMouseDown() {
|
|
244
|
+
this.isInteractingWithPopover = true;
|
|
245
|
+
}
|
|
246
|
+
onPopoverMouseUp() {
|
|
247
|
+
this.isInteractingWithPopover = false;
|
|
233
248
|
}
|
|
234
249
|
hostkeys(event) {
|
|
235
250
|
if (this.isOpen && event.key === "Escape") {
|
|
@@ -261,7 +276,7 @@ TooltipDefinition.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", vers
|
|
|
261
276
|
[attr.aria-expanded]="isOpen"
|
|
262
277
|
[attr.aria-describedby]="isOpen ? id : null"
|
|
263
278
|
(blur)="onBlur($event)"
|
|
264
|
-
(
|
|
279
|
+
(mousedown)="onClick($event)"
|
|
265
280
|
type="button">
|
|
266
281
|
<ng-content></ng-content>
|
|
267
282
|
</button>
|
|
@@ -270,7 +285,9 @@ TooltipDefinition.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", vers
|
|
|
270
285
|
class="cds--popover"
|
|
271
286
|
[id]="id"
|
|
272
287
|
[attr.aria-hidden]="!isOpen"
|
|
273
|
-
role="tooltip"
|
|
288
|
+
role="tooltip"
|
|
289
|
+
(mousedown)="onPopoverMouseDown()"
|
|
290
|
+
(mouseup)="onPopoverMouseUp()">
|
|
274
291
|
<span class="cds--popover-content cds--definition-tooltip" aria-live="polite">
|
|
275
292
|
<ng-container *ngIf="!isTemplate(description)">{{description}}</ng-container>
|
|
276
293
|
<ng-template *ngIf="isTemplate(description)" [ngTemplateOutlet]="description" [ngTemplateOutletContext]="{ $implicit: templateContext }"></ng-template>
|
|
@@ -291,7 +308,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.3.0", ngImpor
|
|
|
291
308
|
[attr.aria-expanded]="isOpen"
|
|
292
309
|
[attr.aria-describedby]="isOpen ? id : null"
|
|
293
310
|
(blur)="onBlur($event)"
|
|
294
|
-
(
|
|
311
|
+
(mousedown)="onClick($event)"
|
|
295
312
|
type="button">
|
|
296
313
|
<ng-content></ng-content>
|
|
297
314
|
</button>
|
|
@@ -300,7 +317,9 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.3.0", ngImpor
|
|
|
300
317
|
class="cds--popover"
|
|
301
318
|
[id]="id"
|
|
302
319
|
[attr.aria-hidden]="!isOpen"
|
|
303
|
-
role="tooltip"
|
|
320
|
+
role="tooltip"
|
|
321
|
+
(mousedown)="onPopoverMouseDown()"
|
|
322
|
+
(mouseup)="onPopoverMouseUp()">
|
|
304
323
|
<span class="cds--popover-content cds--definition-tooltip" aria-live="polite">
|
|
305
324
|
<ng-container *ngIf="!isTemplate(description)">{{description}}</ng-container>
|
|
306
325
|
<ng-template *ngIf="isTemplate(description)" [ngTemplateOutlet]="description" [ngTemplateOutletContext]="{ $implicit: templateContext }"></ng-template>
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"carbon-components-angular-tooltip.mjs","sources":["../../src/tooltip/tooltip.interface.ts","../../src/tooltip/tooltip.component.ts","../../src/tooltip/definition-tooptip.component.ts","../../src/tooltip/tooltip.module.ts","../../src/tooltip/carbon-components-angular-tooltip.ts"],"sourcesContent":["import { TemplateRef } from \"@angular/core\";\n\nexport type TooltipAlignments = \"top\" | \"top-left\" | \"top-right\" |\n\t\"bottom\" | \"bottom-left\" | \"bottom-right\" |\n\t\"left\" | \"left-bottom\" | \"left-top\" |\n\t\"right\" | \"right-bottom\" | \"right-top\";\n\n/**\n * Tooltip attributes\n */\nexport interface TooltipConfig {\n\t/**\n\t * The string or template content to be exposed by the tooltip.\n\t */\n\tdescription: string | TemplateRef<any>;\n\t/**\n\t * Specify the tooltip alignement\n\t */\n\talign?: TooltipAlignments;\n\t/**\n\t * Set to `false` to hide caret\n\t */\n\tcaret?: boolean;\n\t/**\n\t * Set to `false` to hide shadow\n\t */\n\tdropShadow?: boolean;\n\t/**\n\t * Set to `true` to enable high contrast\n\t */\n\thighContrast?: boolean;\n\t/**\n\t * Set to `true` to have the popover open by default\n\t * Tooltip will not remain open if user interacts with it (mouseenter & leave) or clicks anywhere in window\n\t */\n\tisOpen?: boolean;\n\t/**\n\t * Set delay before tooltip is shown\n\t */\n\tenterDelayMs?: number;\n\t/**\n\t * Set delay when tooltip disappears\n\t */\n\tleaveDelayMs?: number;\n}\n\n/**\n * Default tooltip configuration for components to populate missing interface attributes\n */\nexport const DEFAULT_TOOLTIP_CONFIG = {\n\talign: \"bottom\" as TooltipAlignments,\n\tcaret: true,\n\tdropShadow: true,\n\thighContrast: true,\n\tisOpen: false,\n\tenterDelayMs: 100,\n\tleaveDelayMs: 300\n};\n","import {\n\tAfterContentChecked,\n\tChangeDetectionStrategy,\n\tChangeDetectorRef,\n\tComponent,\n\tElementRef,\n\tHostBinding,\n\tHostListener,\n\tInput,\n\tNgZone,\n\tOnChanges,\n\tRenderer2,\n\tSimpleChanges,\n\tTemplateRef,\n\tViewChild\n} from \"@angular/core\";\nimport { PopoverContainer } from \"carbon-components-angular/popover\";\n\n/**\n * Get started with importing the module:\n *\n * ```typescript\n * import { TooltipModule } from 'carbon-components-angular';\n * ```\n *\n * [See demo](../../?path=/story/components-tooltip--basic)\n */\n@Component({\n\tselector: \"cds-tooltip, ibm-tooltip\",\n\tchangeDetection: ChangeDetectionStrategy.OnPush,\n\ttemplate: `\n\t\t<span #contentWrapper>\n\t\t\t<ng-content></ng-content>\n\t\t</span>\n\t\t<span\n\t\t\t*ngIf=\"description\"\n\t\t\tclass=\"cds--popover\"\n\t\t\t[id]=\"id\"\n\t\t\t[attr.aria-hidden]=\"!isOpen\"\n\t\t\trole=\"tooltip\">\n\t\t\t<ng-container *ngIf=\"!disabled\">\n\t\t\t\t<span class=\"cds--popover-content cds--tooltip-content\">\n\t\t\t\t\t<ng-container *ngIf=\"!isTemplate(description)\">{{description}}</ng-container>\n\t\t\t\t\t<ng-template *ngIf=\"isTemplate(description)\" [ngTemplateOutlet]=\"description\" [ngTemplateOutletContext]=\"{ $implicit: templateContext }\"></ng-template>\n\t\t\t\t\t<span *ngIf=\"autoAlign\" class=\"cds--popover-caret cds--popover--auto-align\"></span>\n\t\t\t\t</span>\n\t\t\t\t<span *ngIf=\"!autoAlign\" class=\"cds--popover-caret\"></span>\n\t\t\t</ng-container>\n\t\t</span>\n\t`\n})\nexport class Tooltip extends PopoverContainer implements OnChanges, AfterContentChecked {\n\tstatic tooltipCount = 0;\n\n\t@HostBinding(\"class.cds--tooltip\") tooltipClass = true;\n\n\t@Input() id = `tooltip-${Tooltip.tooltipCount++}`;\n\t/**\n\t * Set delay before tooltip is shown\n\t */\n\t@Input() enterDelayMs = 100;\n\t/**\n\t * Set delay when tooltip disappears\n\t */\n\t@Input() leaveDelayMs = 300;\n\t/**\n\t * Prevent tooltip from showing, used by icon button\n\t */\n\t@Input() disabled = false;\n\t/**\n\t * The string or template content to be exposed by the tooltip.\n\t */\n\t@Input() description: string | TemplateRef<any>;\n\t/**\n\t * Optional data for templates passed as implicit context\n\t */\n\t@Input() templateContext: any;\n\n\t@ViewChild(\"contentWrapper\") wrapper: ElementRef<HTMLSpanElement>;\n\n\tprivate timeoutId: any; // it should be number, but setTimeout below is matching the NodeJs type instead of the JS type\n\n\tconstructor(\n\t\tprotected elementRef: ElementRef,\n\t\tprotected ngZone: NgZone,\n\t\tprotected renderer: Renderer2,\n\t\tprotected changeDetectorRef: ChangeDetectorRef\n\t) {\n\t\tsuper(elementRef, ngZone, renderer, changeDetectorRef);\n\t\tthis.highContrast = true;\n\t\tthis.dropShadow = false;\n\t}\n\n\t@HostListener(\"mouseenter\", [\"$event\"])\n\tmouseenter(event) {\n\t\t// If a mouseleave is triggered before the tooltip is displayed (before setTimeout of mouseenter completes)\n\t\t// we trigger the mouseleave only avoiding having to unecessary show the tooltip\n\t\tclearTimeout(this.timeoutId);\n\t\tthis.timeoutId = setTimeout(() => {\n\t\t\tthis.handleChange(true, event);\n\t\t}, this.enterDelayMs);\n\t}\n\n\t@HostListener(\"mouseleave\", [\"$event\"])\n\tmouseleave(event) {\n\t\t// If a mouseleave is triggered before the tooltip is displayed (before setTimeout of mouseenter completes)\n\t\t// we trigger the mouseleave only avoiding having to unecessary show the tooltip\n\t\tclearTimeout(this.timeoutId);\n\t\tthis.timeoutId = setTimeout(() => {\n\t\t\tthis.handleChange(false, event);\n\t\t}, this.leaveDelayMs);\n\t}\n\n\t@HostListener(\"keyup\", [\"$event\"])\n\thostkeys(event: KeyboardEvent) {\n\t\tif (open && event.key === \"Escape\") {\n\t\t\tevent.stopPropagation();\n\t\t\tthis.handleChange(false, event);\n\t\t}\n\t}\n\n\t// We are not focusing on entire popover, only the trigger\n\t@HostListener(\"focusin\", [\"$event\"])\n\thandleFocus(event: Event) {\n\t\tthis.handleChange(true, event);\n\t}\n\n\t@HostListener(\"focusout\", [\"$event\"])\n\thandleFocusOut(event: Event) {\n\t\tthis.handleChange(false, event);\n\t}\n\n\tisTemplate(value) {\n\t\treturn value instanceof TemplateRef;\n\t}\n\n\t/**\n\t * Close the popover and reopen it with updated values without emitting an event\n\t * @param changes\n\t */\n\tngOnChanges(changes: SimpleChanges): void {\n\t\t// Close and reopen the popover, handle alignment/programmatic open/close\n\t\tconst originalState = this.isOpen;\n\t\tthis.handleChange(false);\n\n\t\t// Ignore first change since content is not initialized\n\t\tif (\n\t\t\t(changes.autoAlign && !changes.autoAlign.firstChange)\n\t\t\t|| (changes.disabled && !changes.disabled.firstChange && !changes.disabled.currentValue)\n\t\t\t// If description is set to empty string when open & autoAlign is true then set to a new value\n\t\t\t// positioning of popover is broken because popover content ref/caret no longer exists\n\t\t\t|| changes.description\n\t\t) {\n\t\t\t/**\n\t\t\t * When `disabled` is `true`, popover content node is removed. So when re-enabling `disabled`,\n\t\t\t * we manually update view so querySelector can detect the popover content node.\n\t\t\t * Otherwise, the position of the popover will be incorrect when autoAlign is enabled.\n\t\t\t */\n\t\t\tthis.changeDetectorRef.detectChanges();\n\n\t\t\t// Reset the inline styles\n\t\t\tthis.popoverContentRef = this.elementRef.nativeElement.querySelector(\".cds--popover-content\");\n\t\t\tthis.popoverContentRef?.setAttribute(\"style\", \"\");\n\t\t\tthis.caretRef = this.elementRef.nativeElement.querySelector(\"span.cds--popover-caret\");\n\t\t}\n\n\t\tthis.handleChange(originalState);\n\t}\n\n\t/**\n\t * Check for any changes in the projected content & apply accessibility attribute if needed\n\t */\n\tngAfterContentChecked() {\n\t\tif (this.wrapper) {\n\t\t\tconst buttonElement = this.wrapper.nativeElement.querySelector(\"button\");\n\t\t\tif (buttonElement && !buttonElement.getAttribute(\"aria-labelledby\")) {\n\t\t\t\tbuttonElement.setAttribute(\"aria-labelledby\", this.id);\n\t\t\t}\n\t\t}\n\t}\n}\n","import {\n\tChangeDetectionStrategy,\n\tChangeDetectorRef,\n\tComponent,\n\tElementRef,\n\tHostListener,\n\tInput,\n\tNgZone,\n\tRenderer2,\n\tTemplateRef\n} from \"@angular/core\";\nimport { PopoverContainer } from \"carbon-components-angular/popover\";\n\n/**\n * Get started with importing the module:\n *\n * ```typescript\n * import { TooltipModule } from 'carbon-components-angular';\n * ```\n *\n * [See demo](../../?path=/story/components-tooltip-definition--basic)\n */\n@Component({\n\tselector: \"cds-tooltip-definition, ibm-tooltip-definition\",\n\tchangeDetection: ChangeDetectionStrategy.OnPush,\n\ttemplate: `\n\t\t<button\n\t\t\tclass=\"cds--definition-term\"\n\t\t\t[attr.aria-controls]=\"id\"\n\t\t\t[attr.aria-expanded]=\"isOpen\"\n\t\t\t[attr.aria-describedby]=\"isOpen ? id : null\"\n\t\t\t(blur)=\"onBlur($event)\"\n\t\t\t(click)=\"onClick($event)\"\n\t\t\ttype=\"button\">\n\t\t\t<ng-content></ng-content>\n\t\t</button>\n\t\t<span\n\t\t\t*ngIf=\"description\"\n\t\t\tclass=\"cds--popover\"\n\t\t\t[id]=\"id\"\n\t\t\t[attr.aria-hidden]=\"!isOpen\"\n\t\t\trole=\"tooltip\">\n\t\t\t<span class=\"cds--popover-content cds--definition-tooltip\" aria-live=\"polite\">\n\t\t\t\t<ng-container *ngIf=\"!isTemplate(description)\">{{description}}</ng-container>\n\t\t\t\t<ng-template *ngIf=\"isTemplate(description)\" [ngTemplateOutlet]=\"description\" [ngTemplateOutletContext]=\"{ $implicit: templateContext }\"></ng-template>\n\t\t\t\t<span *ngIf=\"autoAlign\" class=\"cds--popover-caret cds--popover--auto-align\"></span>\n\t\t\t</span>\n\t\t\t<span *ngIf=\"!autoAlign\" class=\"cds--popover-caret\"></span>\n\t\t</span>\n\t`\n})\nexport class TooltipDefinition extends PopoverContainer {\n\tstatic tooltipCount = 0;\n\n\t@Input() id = `tooltip-definition-${TooltipDefinition.tooltipCount++}`;\n\n\t/**\n\t * The string or template content to be exposed by the tooltip.\n\t */\n\t@Input() description: string | TemplateRef<any>;\n\t/**\n\t * Optional data for templates passed as implicit context\n\t */\n\t@Input() templateContext: any;\n\n\t@Input() openOnHover = false;\n\n\tconstructor(\n\t\tprotected elementRef: ElementRef,\n\t\tprotected ngZone: NgZone,\n\t\tprotected renderer: Renderer2,\n\t\tprotected changeDetectorRef: ChangeDetectorRef\n\t) {\n\t\tsuper(elementRef, ngZone, renderer, changeDetectorRef);\n\t\tthis.highContrast = true;\n\t\tthis.dropShadow = false;\n\t}\n\n\tonBlur(event: Event) {\n\t\tthis.handleChange(false, event);\n\t}\n\n\tonClick(event: Event) {\n\t\tthis.handleChange(!this.isOpen, event);\n\t}\n\n\t@HostListener(\"keyup\", [\"$event\"])\n\thostkeys(event: KeyboardEvent) {\n\t\tif (this.isOpen && event.key === \"Escape\") {\n\t\t\tevent.stopPropagation();\n\t\t\tthis.handleChange(false, event);\n\t\t}\n\t}\n\n\t@HostListener(\"mouseleave\", [\"$event\"])\n\tmouseleave(event) {\n\t\tthis.handleChange(false, event);\n\t}\n\n\t@HostListener(\"mouseenter\", [\"$event\"])\n\tmouseenter(event) {\n\t\tif (this.openOnHover) {\n\t\t\tthis.handleChange(true, event);\n\t\t}\n\t}\n\n\t@HostListener(\"focusin\", [\"$event\"])\n\tonFocus(event) {\n\t\tthis.handleChange(true, event);\n\t}\n\n\tpublic isTemplate(value) {\n\t\treturn value instanceof TemplateRef;\n\t}\n}\n","import { NgModule } from \"@angular/core\";\nimport { CommonModule } from \"@angular/common\";\n\nimport { PopoverModule } from \"carbon-components-angular/popover\";\nimport { Tooltip } from \"./tooltip.component\";\nimport { TooltipDefinition } from \"./definition-tooptip.component\";\n\n@NgModule({\n\tdeclarations: [\n\t\tTooltip,\n\t\tTooltipDefinition\n\t],\n\texports: [\n\t\tTooltip,\n\t\tTooltipDefinition\n\t],\n\timports: [CommonModule, PopoverModule]\n})\nexport class TooltipModule {}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;;AA8CA;;AAEG;AACU,MAAA,sBAAsB,GAAG;AACrC,IAAA,KAAK,EAAE,QAA6B;AACpC,IAAA,KAAK,EAAE,IAAI;AACX,IAAA,UAAU,EAAE,IAAI;AAChB,IAAA,YAAY,EAAE,IAAI;AAClB,IAAA,MAAM,EAAE,KAAK;AACb,IAAA,YAAY,EAAE,GAAG;AACjB,IAAA,YAAY,EAAE,GAAG;;;ACtClB;;;;;;;;AAQG;AAyBG,MAAO,OAAQ,SAAQ,gBAAgB,CAAA;AA+B5C,IAAA,WAAA,CACW,UAAsB,EACtB,MAAc,EACd,QAAmB,EACnB,iBAAoC,EAAA;QAE9C,KAAK,CAAC,UAAU,EAAE,MAAM,EAAE,QAAQ,EAAE,iBAAiB,CAAC,CAAC;QAL7C,IAAU,CAAA,UAAA,GAAV,UAAU,CAAY;QACtB,IAAM,CAAA,MAAA,GAAN,MAAM,CAAQ;QACd,IAAQ,CAAA,QAAA,GAAR,QAAQ,CAAW;QACnB,IAAiB,CAAA,iBAAA,GAAjB,iBAAiB,CAAmB;QAhCZ,IAAY,CAAA,YAAA,GAAG,IAAI,CAAC;AAE9C,QAAA,IAAA,CAAA,EAAE,GAAG,CAAW,QAAA,EAAA,OAAO,CAAC,YAAY,EAAE,EAAE,CAAC;AAClD;;AAEG;QACM,IAAY,CAAA,YAAA,GAAG,GAAG,CAAC;AAC5B;;AAEG;QACM,IAAY,CAAA,YAAA,GAAG,GAAG,CAAC;AAC5B;;AAEG;QACM,IAAQ,C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AAA;;;MCxFvB,aAAa,CAAA;;0GAAb,aAAa,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,QAAA,EAAA,CAAA,CAAA;AAAb,aAAA,CAAA,IAAA,GAAA,EAAA,CAAA,mBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,QAAA,EAAA,QAAA,EAAA,EAAA,EAAA,IAAA,EAAA,aAAa,iBATxB,OAAO;AACP,QAAA,iBAAiB,CAMR,EAAA,OAAA,EAAA,CAAA,YAAY,EAAE,aAAa,aAHpC,OAAO;QACP,iBAAiB,CAAA,EAAA,CAAA,CAAA;2GAIN,aAAa,EAAA,OAAA,EAAA,CAFf,YAAY,EAAE,aAAa,CAAA,EAAA,CAAA,CAAA;2FAEzB,aAAa,EAAA,UAAA,EAAA,CAAA;kBAXzB,QAAQ;AAAC,YAAA,IAAA,EAAA,CAAA;AACT,oBAAA,YAAY,EAAE;wBACb,OAAO;wBACP,iBAAiB;AACjB,qBAAA;AACD,oBAAA,OAAO,EAAE;wBACR,OAAO;wBACP,iBAAiB;AACjB,qBAAA;AACD,oBAAA,OAAO,EAAE,CAAC,YAAY,EAAE,aAAa,CAAC;AACtC,iBAAA,CAAA;;;ACjBD;;AAEG;;;;"}
|
|
1
|
+
{"version":3,"file":"carbon-components-angular-tooltip.mjs","sources":["../../src/tooltip/tooltip.interface.ts","../../src/tooltip/tooltip.component.ts","../../src/tooltip/definition-tooptip.component.ts","../../src/tooltip/tooltip.module.ts","../../src/tooltip/carbon-components-angular-tooltip.ts"],"sourcesContent":["import { TemplateRef } from \"@angular/core\";\n\nexport type TooltipAlignments = \"top\" | \"top-left\" | \"top-right\" |\n\t\"bottom\" | \"bottom-left\" | \"bottom-right\" |\n\t\"left\" | \"left-bottom\" | \"left-top\" |\n\t\"right\" | \"right-bottom\" | \"right-top\";\n\n/**\n * Tooltip attributes\n */\nexport interface TooltipConfig {\n\t/**\n\t * The string or template content to be exposed by the tooltip.\n\t */\n\tdescription: string | TemplateRef<any>;\n\t/**\n\t * Specify the tooltip alignement\n\t */\n\talign?: TooltipAlignments;\n\t/**\n\t * Set to `false` to hide caret\n\t */\n\tcaret?: boolean;\n\t/**\n\t * Set to `false` to hide shadow\n\t */\n\tdropShadow?: boolean;\n\t/**\n\t * Set to `true` to enable high contrast\n\t */\n\thighContrast?: boolean;\n\t/**\n\t * Set to `true` to have the popover open by default\n\t * Tooltip will not remain open if user interacts with it (mouseenter & leave) or clicks anywhere in window\n\t */\n\tisOpen?: boolean;\n\t/**\n\t * Set delay before tooltip is shown\n\t */\n\tenterDelayMs?: number;\n\t/**\n\t * Set delay when tooltip disappears\n\t */\n\tleaveDelayMs?: number;\n}\n\n/**\n * Default tooltip configuration for components to populate missing interface attributes\n */\nexport const DEFAULT_TOOLTIP_CONFIG = {\n\talign: \"bottom\" as TooltipAlignments,\n\tcaret: true,\n\tdropShadow: true,\n\thighContrast: true,\n\tisOpen: false,\n\tenterDelayMs: 100,\n\tleaveDelayMs: 300\n};\n","import {\n\tAfterContentChecked,\n\tChangeDetectionStrategy,\n\tChangeDetectorRef,\n\tComponent,\n\tElementRef,\n\tHostBinding,\n\tHostListener,\n\tInput,\n\tNgZone,\n\tOnChanges,\n\tRenderer2,\n\tSimpleChanges,\n\tTemplateRef,\n\tViewChild\n} from \"@angular/core\";\nimport { PopoverContainer } from \"carbon-components-angular/popover\";\n\n/**\n * Get started with importing the module:\n *\n * ```typescript\n * import { TooltipModule } from 'carbon-components-angular';\n * ```\n *\n * [See demo](../../?path=/story/components-tooltip--basic)\n */\n@Component({\n\tselector: \"cds-tooltip, ibm-tooltip\",\n\tchangeDetection: ChangeDetectionStrategy.OnPush,\n\ttemplate: `\n\t\t<span #contentWrapper>\n\t\t\t<ng-content></ng-content>\n\t\t</span>\n\t\t<span\n\t\t\t*ngIf=\"description\"\n\t\t\tclass=\"cds--popover\"\n\t\t\t[id]=\"id\"\n\t\t\t[attr.aria-hidden]=\"!isOpen\"\n\t\t\trole=\"tooltip\">\n\t\t\t<ng-container *ngIf=\"!disabled\">\n\t\t\t\t<span class=\"cds--popover-content cds--tooltip-content\">\n\t\t\t\t\t<ng-container *ngIf=\"!isTemplate(description)\">{{description}}</ng-container>\n\t\t\t\t\t<ng-template *ngIf=\"isTemplate(description)\" [ngTemplateOutlet]=\"description\" [ngTemplateOutletContext]=\"{ $implicit: templateContext }\"></ng-template>\n\t\t\t\t\t<span *ngIf=\"autoAlign\" class=\"cds--popover-caret cds--popover--auto-align\"></span>\n\t\t\t\t</span>\n\t\t\t\t<span *ngIf=\"!autoAlign\" class=\"cds--popover-caret\"></span>\n\t\t\t</ng-container>\n\t\t</span>\n\t`\n})\nexport class Tooltip extends PopoverContainer implements OnChanges, AfterContentChecked {\n\tstatic tooltipCount = 0;\n\n\t@HostBinding(\"class.cds--tooltip\") tooltipClass = true;\n\n\t@Input() id = `tooltip-${Tooltip.tooltipCount++}`;\n\t/**\n\t * Set delay before tooltip is shown\n\t */\n\t@Input() enterDelayMs = 100;\n\t/**\n\t * Set delay when tooltip disappears\n\t */\n\t@Input() leaveDelayMs = 300;\n\t/**\n\t * Prevent tooltip from showing, used by icon button\n\t */\n\t@Input() disabled = false;\n\t/**\n\t * The string or template content to be exposed by the tooltip.\n\t */\n\t@Input() description: string | TemplateRef<any>;\n\t/**\n\t * Optional data for templates passed as implicit context\n\t */\n\t@Input() templateContext: any;\n\n\t@ViewChild(\"contentWrapper\") wrapper: ElementRef<HTMLSpanElement>;\n\n\tprivate timeoutId: any; // it should be number, but setTimeout below is matching the NodeJs type instead of the JS type\n\n\tconstructor(\n\t\tprotected elementRef: ElementRef,\n\t\tprotected ngZone: NgZone,\n\t\tprotected renderer: Renderer2,\n\t\tprotected changeDetectorRef: ChangeDetectorRef\n\t) {\n\t\tsuper(elementRef, ngZone, renderer, changeDetectorRef);\n\t\tthis.highContrast = true;\n\t\tthis.dropShadow = false;\n\t}\n\n\t@HostListener(\"mouseenter\", [\"$event\"])\n\tmouseenter(event) {\n\t\t// If a mouseleave is triggered before the tooltip is displayed (before setTimeout of mouseenter completes)\n\t\t// we trigger the mouseleave only avoiding having to unecessary show the tooltip\n\t\tclearTimeout(this.timeoutId);\n\t\tthis.timeoutId = setTimeout(() => {\n\t\t\tthis.handleChange(true, event);\n\t\t}, this.enterDelayMs);\n\t}\n\n\t@HostListener(\"mouseleave\", [\"$event\"])\n\tmouseleave(event) {\n\t\t// If a mouseleave is triggered before the tooltip is displayed (before setTimeout of mouseenter completes)\n\t\t// we trigger the mouseleave only avoiding having to unecessary show the tooltip\n\t\tclearTimeout(this.timeoutId);\n\t\tthis.timeoutId = setTimeout(() => {\n\t\t\tthis.handleChange(false, event);\n\t\t}, this.leaveDelayMs);\n\t}\n\n\t@HostListener(\"keyup\", [\"$event\"])\n\thostkeys(event: KeyboardEvent) {\n\t\tif (open && event.key === \"Escape\") {\n\t\t\tevent.stopPropagation();\n\t\t\tthis.handleChange(false, event);\n\t\t}\n\t}\n\n\t// We are not focusing on entire popover, only the trigger\n\t@HostListener(\"focusin\", [\"$event\"])\n\thandleFocus(event: Event) {\n\t\tthis.handleChange(true, event);\n\t}\n\n\t@HostListener(\"focusout\", [\"$event\"])\n\thandleFocusOut(event: Event) {\n\t\tthis.handleChange(false, event);\n\t}\n\n\tisTemplate(value) {\n\t\treturn value instanceof TemplateRef;\n\t}\n\n\t/**\n\t * Close the popover and reopen it with updated values without emitting an event\n\t * @param changes\n\t */\n\tngOnChanges(changes: SimpleChanges): void {\n\t\t// Close and reopen the popover, handle alignment/programmatic open/close\n\t\tconst originalState = this.isOpen;\n\t\tthis.handleChange(false);\n\n\t\t// Ignore first change since content is not initialized\n\t\tif (\n\t\t\t(changes.autoAlign && !changes.autoAlign.firstChange)\n\t\t\t|| (changes.disabled && !changes.disabled.firstChange && !changes.disabled.currentValue)\n\t\t\t// If description is set to empty string when open & autoAlign is true then set to a new value\n\t\t\t// positioning of popover is broken because popover content ref/caret no longer exists\n\t\t\t|| changes.description\n\t\t) {\n\t\t\t/**\n\t\t\t * When `disabled` is `true`, popover content node is removed. So when re-enabling `disabled`,\n\t\t\t * we manually update view so querySelector can detect the popover content node.\n\t\t\t * Otherwise, the position of the popover will be incorrect when autoAlign is enabled.\n\t\t\t */\n\t\t\tthis.changeDetectorRef.detectChanges();\n\n\t\t\t// Reset the inline styles\n\t\t\tthis.popoverContentRef = this.elementRef.nativeElement.querySelector(\".cds--popover-content\");\n\t\t\tthis.popoverContentRef?.setAttribute(\"style\", \"\");\n\t\t\tthis.caretRef = this.elementRef.nativeElement.querySelector(\"span.cds--popover-caret\");\n\t\t}\n\n\t\tthis.handleChange(originalState);\n\t}\n\n\t/**\n\t * Check for any changes in the projected content & apply accessibility attribute if needed\n\t */\n\tngAfterContentChecked() {\n\t\tif (this.wrapper) {\n\t\t\tconst buttonElement = this.wrapper.nativeElement.querySelector(\"button\");\n\t\t\tif (buttonElement && !buttonElement.getAttribute(\"aria-labelledby\")) {\n\t\t\t\tbuttonElement.setAttribute(\"aria-labelledby\", this.id);\n\t\t\t}\n\t\t}\n\t}\n}\n","import {\n\tChangeDetectionStrategy,\n\tChangeDetectorRef,\n\tComponent,\n\tElementRef,\n\tHostListener,\n\tInput,\n\tNgZone,\n\tRenderer2,\n\tTemplateRef\n} from \"@angular/core\";\nimport { PopoverContainer } from \"carbon-components-angular/popover\";\n\n/**\n * Get started with importing the module:\n *\n * ```typescript\n * import { TooltipModule } from 'carbon-components-angular';\n * ```\n *\n * [See demo](../../?path=/story/components-tooltip-definition--basic)\n */\n@Component({\n\tselector: \"cds-tooltip-definition, ibm-tooltip-definition\",\n\tchangeDetection: ChangeDetectionStrategy.OnPush,\n\ttemplate: `\n\t\t<button\n\t\t\tclass=\"cds--definition-term\"\n\t\t\t[attr.aria-controls]=\"id\"\n\t\t\t[attr.aria-expanded]=\"isOpen\"\n\t\t\t[attr.aria-describedby]=\"isOpen ? id : null\"\n\t\t\t(blur)=\"onBlur($event)\"\n\t\t\t(mousedown)=\"onClick($event)\"\n\t\t\ttype=\"button\">\n\t\t\t<ng-content></ng-content>\n\t\t</button>\n\t\t<span\n\t\t\t*ngIf=\"description\"\n\t\t\tclass=\"cds--popover\"\n\t\t\t[id]=\"id\"\n\t\t\t[attr.aria-hidden]=\"!isOpen\"\n\t\t\trole=\"tooltip\"\n\t\t\t(mousedown)=\"onPopoverMouseDown()\"\n\t\t\t(mouseup)=\"onPopoverMouseUp()\">\n\t\t\t<span class=\"cds--popover-content cds--definition-tooltip\" aria-live=\"polite\">\n\t\t\t\t<ng-container *ngIf=\"!isTemplate(description)\">{{description}}</ng-container>\n\t\t\t\t<ng-template *ngIf=\"isTemplate(description)\" [ngTemplateOutlet]=\"description\" [ngTemplateOutletContext]=\"{ $implicit: templateContext }\"></ng-template>\n\t\t\t\t<span *ngIf=\"autoAlign\" class=\"cds--popover-caret cds--popover--auto-align\"></span>\n\t\t\t</span>\n\t\t\t<span *ngIf=\"!autoAlign\" class=\"cds--popover-caret\"></span>\n\t\t</span>\n\t`\n})\nexport class TooltipDefinition extends PopoverContainer {\n\tstatic tooltipCount = 0;\n\n\t@Input() id = `tooltip-definition-${TooltipDefinition.tooltipCount++}`;\n\n\t/**\n\t * The string or template content to be exposed by the tooltip.\n\t */\n\t@Input() description: string | TemplateRef<any>;\n\t/**\n\t * Optional data for templates passed as implicit context\n\t */\n\t@Input() templateContext: any;\n\n\t@Input() openOnHover = false;\n\n\t/**\n\t * Helper variable to ensure button blur doesn't fire on `click` of popover content\n\t */\n\tprivate isInteractingWithPopover = false;\n\n\tconstructor(\n\t\tprotected elementRef: ElementRef,\n\t\tprotected ngZone: NgZone,\n\t\tprotected renderer: Renderer2,\n\t\tprotected changeDetectorRef: ChangeDetectorRef\n\t) {\n\t\tsuper(elementRef, ngZone, renderer, changeDetectorRef);\n\t\tthis.highContrast = true;\n\t\tthis.dropShadow = false;\n\t}\n\n\tonBlur(event: Event) {\n\t\t// Only close if user is not interacting with popover content\n\t\tif (!this.isInteractingWithPopover) {\n\t\t\tthis.handleChange(false, event);\n\t\t}\n\t}\n\n\tonClick(event: MouseEvent) {\n\t\tif (event.button === 0) {\n\t\t\tthis.handleChange(!this.isOpen, event);\n\t\t}\n\t}\n\n\tonPopoverMouseDown() {\n\t\tthis.isInteractingWithPopover = true;\n\t}\n\n\tonPopoverMouseUp() {\n\t\tthis.isInteractingWithPopover = false;\n\t}\n\n\t@HostListener(\"keyup\", [\"$event\"])\n\thostkeys(event: KeyboardEvent) {\n\t\tif (this.isOpen && event.key === \"Escape\") {\n\t\t\tevent.stopPropagation();\n\t\t\tthis.handleChange(false, event);\n\t\t}\n\t}\n\n\t@HostListener(\"mouseleave\", [\"$event\"])\n\tmouseleave(event) {\n\t\tthis.handleChange(false, event);\n\t}\n\n\t@HostListener(\"mouseenter\", [\"$event\"])\n\tmouseenter(event) {\n\t\tif (this.openOnHover) {\n\t\t\tthis.handleChange(true, event);\n\t\t}\n\t}\n\n\t@HostListener(\"focusin\", [\"$event\"])\n\tonFocus(event) {\n\t\tthis.handleChange(true, event);\n\t}\n\n\tpublic isTemplate(value) {\n\t\treturn value instanceof TemplateRef;\n\t}\n}\n","import { NgModule } from \"@angular/core\";\nimport { CommonModule } from \"@angular/common\";\n\nimport { PopoverModule } from \"carbon-components-angular/popover\";\nimport { Tooltip } from \"./tooltip.component\";\nimport { TooltipDefinition } from \"./definition-tooptip.component\";\n\n@NgModule({\n\tdeclarations: [\n\t\tTooltip,\n\t\tTooltipDefinition\n\t],\n\texports: [\n\t\tTooltip,\n\t\tTooltipDefinition\n\t],\n\timports: [CommonModule, PopoverModule]\n})\nexport class TooltipModule {}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;;AA8CA;;AAEG;AACU,MAAA,sBAAsB,GAAG;AACrC,IAAA,KAAK,EAAE,QAA6B;AACpC,IAAA,KAAK,EAAE,IAAI;AACX,IAAA,UAAU,EAAE,IAAI;AAChB,IAAA,YAAY,EAAE,IAAI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AA;AAAb,aAAA,CAAA,IAAA,GAAA,EAAA,CAAA,mBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,QAAA,EAAA,QAAA,EAAA,EAAA,EAAA,IAAA,EAAA,aAAa,iBATxB,OAAO;AACP,QAAA,iBAAiB,CAMR,EAAA,OAAA,EAAA,CAAA,YAAY,EAAE,aAAa,aAHpC,OAAO;QACP,iBAAiB,CAAA,EAAA,CAAA,CAAA;2GAIN,aAAa,EAAA,OAAA,EAAA,CAFf,YAAY,EAAE,aAAa,CAAA,EAAA,CAAA,CAAA;2FAEzB,aAAa,EAAA,UAAA,EAAA,CAAA;kBAXzB,QAAQ;AAAC,YAAA,IAAA,EAAA,CAAA;AACT,oBAAA,YAAY,EAAE;wBACb,OAAO;wBACP,iBAAiB;AACjB,qBAAA;AACD,oBAAA,OAAO,EAAE;wBACR,OAAO;wBACP,iBAAiB;AACjB,qBAAA;AACD,oBAAA,OAAO,EAAE,CAAC,YAAY,EAAE,aAAa,CAAC;AACtC,iBAAA,CAAA;;;ACjBD;;AAEG;;;;"}
|
package/package.json
CHANGED
|
@@ -46,9 +46,15 @@ export declare class TooltipDefinition extends PopoverContainer {
|
|
|
46
46
|
*/
|
|
47
47
|
templateContext: any;
|
|
48
48
|
openOnHover: boolean;
|
|
49
|
+
/**
|
|
50
|
+
* Helper variable to ensure button blur doesn't fire on `click` of popover content
|
|
51
|
+
*/
|
|
52
|
+
private isInteractingWithPopover;
|
|
49
53
|
constructor(elementRef: ElementRef, ngZone: NgZone, renderer: Renderer2, changeDetectorRef: ChangeDetectorRef);
|
|
50
54
|
onBlur(event: Event): void;
|
|
51
|
-
onClick(event:
|
|
55
|
+
onClick(event: MouseEvent): void;
|
|
56
|
+
onPopoverMouseDown(): void;
|
|
57
|
+
onPopoverMouseUp(): void;
|
|
52
58
|
hostkeys(event: KeyboardEvent): void;
|
|
53
59
|
mouseleave(event: any): void;
|
|
54
60
|
mouseenter(event: any): void;
|