@coolon/angular-ui-powerups 16.1.0-alpha.255 → 16.1.0-alpha.257
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/components/tables/renderer/table-cell/table-cell.component.mjs +4 -44
- package/esm2022/lib/directives/aup-tooltip.directive.mjs +89 -0
- package/esm2022/lib/directives/directives.module.mjs +14 -5
- package/esm2022/lib/directives/exports.mjs +2 -1
- package/fesm2022/coolon-angular-ui-powerups.mjs +101 -48
- package/fesm2022/coolon-angular-ui-powerups.mjs.map +1 -1
- package/lib/components/tables/renderer/table-cell/table-cell.component.d.ts +0 -26
- package/lib/directives/aup-tooltip.directive.d.ts +52 -0
- package/lib/directives/directives.module.d.ts +15 -13
- package/lib/directives/exports.d.ts +1 -0
- package/package.json +1 -1
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { ChangeDetectionStrategy, Component, HostBinding,
|
|
2
|
-
import {
|
|
1
|
+
import { ChangeDetectionStrategy, Component, HostBinding, Input, } from '@angular/core';
|
|
2
|
+
import { DisposableComponent } from "../../../disposable-component";
|
|
3
3
|
import { AbstractTableModel } from "../../abstract-table-model";
|
|
4
4
|
import { ColumnModel } from "../../column/column-model";
|
|
5
5
|
import { CELL_RENDERER_PORTAL } from "../cell-portal-ref";
|
|
@@ -14,9 +14,6 @@ export class TableCellComponent extends DisposableComponent {
|
|
|
14
14
|
defaultClassNames = 'aup-cell-renderer';
|
|
15
15
|
fillCell = false;
|
|
16
16
|
padChild = false;
|
|
17
|
-
// Nil unless an ancestor aup-table-body opted into detached change detection, which is exactly
|
|
18
|
-
// when the problem refreshOverlaysOnHover() solves can occur.
|
|
19
|
-
detachedParentCdr = this.inject(AUP_DETACHED_PARENT_CDR, { optional: true, skipSelf: true });
|
|
20
17
|
constructor() {
|
|
21
18
|
super();
|
|
22
19
|
this.onInit(() => {
|
|
@@ -38,42 +35,8 @@ export class TableCellComponent extends DisposableComponent {
|
|
|
38
35
|
row: this.row,
|
|
39
36
|
};
|
|
40
37
|
}
|
|
41
|
-
/**
|
|
42
|
-
* A CDK overlay attached through a `ComponentPortal` carrying a `ViewContainerRef` — MatTooltip is
|
|
43
|
-
* the common case — creates its component in the TRIGGER's view container: `attachComponentPortal`
|
|
44
|
-
* takes the `portal.viewContainerRef` branch and skips `ApplicationRef.attachView`, so only the DOM
|
|
45
|
-
* node is relocated to the overlay container. The component stays a change-detection child of THIS
|
|
46
|
-
* cell's view, which `aup-table-body` has detached. MatTooltip only calls `markForCheck()` on it,
|
|
47
|
-
* and nothing sweeps a detached subtree, so the tooltip paints EMPTY. `mouseleave` tears the
|
|
48
|
-
* overlay down, so every RE-hover rebuilds a component that needs a fresh check — which is why the
|
|
49
|
-
* first hover of a cell can look fine and later ones don't.
|
|
50
|
-
*
|
|
51
|
-
* The deferral is the whole trick, and it must be a MACROTASK. `mouseenter` is dispatched as a
|
|
52
|
-
* separate event per entered element, outermost first, so this cell's listener runs in an earlier
|
|
53
|
-
* task than the trigger's — a `queueMicrotask` check drains before MatTooltip has even created the
|
|
54
|
-
* overlay and is measurably a no-op (that is also why `markForCheck()`, which schedules a
|
|
55
|
-
* microtask parent sweep, does not fix this).
|
|
56
|
-
*
|
|
57
|
-
* Scoped to this cell rather than routed through `DisposableComponent.scheduleParentSweep`: both
|
|
58
|
-
* are correct once the timing is right, but the sweep only coalesces within a single microtask, and
|
|
59
|
-
* each `mouseenter` is its own task — so it degenerates into one whole-table-body check per cell
|
|
60
|
-
* entered, where this is one check of a single cell's view.
|
|
61
|
-
*
|
|
62
|
-
* `mouseenter` does not bubble, so this is one event per cell entered; it no-ops entirely for
|
|
63
|
-
* tables that never detached.
|
|
64
|
-
*/
|
|
65
|
-
refreshOverlaysOnHover() {
|
|
66
|
-
if (!this.detachedParentCdr) {
|
|
67
|
-
return;
|
|
68
|
-
}
|
|
69
|
-
setTimeout(() => {
|
|
70
|
-
if (!this.isDisposed()) {
|
|
71
|
-
this.cdr.detectChanges();
|
|
72
|
-
}
|
|
73
|
-
});
|
|
74
|
-
}
|
|
75
38
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.9", ngImport: i0, type: TableCellComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
76
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "16.2.9", type: TableCellComponent, selector: "aup-table-cell", inputs: { row: "row", column: "column", tableModel: "tableModel" }, host: {
|
|
39
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "16.2.9", type: TableCellComponent, selector: "aup-table-cell", inputs: { row: "row", column: "column", tableModel: "tableModel" }, host: { properties: { "class": "this.defaultClassNames", "class.fillCell": "this.fillCell", "class.padChild": "this.padChild" } }, usesInheritance: true, usesOnChanges: true, ngImport: i0, template: "<ng-container [cdkPortalOutlet]=\"getRendererPortal()\" (attached)=\"initialiseRenderer($event)\"></ng-container>\n", styles: [""], dependencies: [{ kind: "directive", type: i1.CdkPortalOutlet, selector: "[cdkPortalOutlet]", inputs: ["cdkPortalOutlet"], outputs: ["attached"], exportAs: ["cdkPortalOutlet"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
77
40
|
}
|
|
78
41
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.9", ngImport: i0, type: TableCellComponent, decorators: [{
|
|
79
42
|
type: Component,
|
|
@@ -93,8 +56,5 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.9", ngImpor
|
|
|
93
56
|
}], padChild: [{
|
|
94
57
|
type: HostBinding,
|
|
95
58
|
args: ['class.padChild']
|
|
96
|
-
}], refreshOverlaysOnHover: [{
|
|
97
|
-
type: HostListener,
|
|
98
|
-
args: ['mouseenter']
|
|
99
59
|
}] } });
|
|
100
|
-
//# sourceMappingURL=data:application/json;base64,
|
|
60
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLC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bnRlbnQodGhpcyk7XG4gIH1cblxuICBnZXRSZW5kZXJlclBvcnRhbCgpIHtcbiAgICByZXR1cm4gdGhpc1tDRUxMX1JFTkRFUkVSX1BPUlRBTF07XG4gIH1cblxuICBnZXRSb3dEYXRhKCk6IFJvd0RhdGE8Um93PiB7XG4gICAgcmV0dXJuIHtcbiAgICAgIHJvdzogdGhpcy5yb3csXG4gICAgfTtcbiAgfVxufVxuIiwiPG5nLWNvbnRhaW5lciBbY2RrUG9ydGFsT3V0bGV0XT1cImdldFJlbmRlcmVyUG9ydGFsKClcIiAoYXR0YWNoZWQpPVwiaW5pdGlhbGlzZVJlbmRlcmVyKCRldmVudClcIj48L25nLWNvbnRhaW5lcj5cbiJdfQ==
|
|
@@ -0,0 +1,89 @@
|
|
|
1
|
+
import { Directive, ViewContainerRef, inject } from '@angular/core';
|
|
2
|
+
import { MatTooltip } from '@angular/material/tooltip';
|
|
3
|
+
import * as i0 from "@angular/core";
|
|
4
|
+
/**
|
|
5
|
+
* `matTooltip` that also renders inside a detached change-detection subtree — i.e. inside an
|
|
6
|
+
* `aup-table` body with `AUP_TABLE_OPTIMIZED_CHANGE_DETECTION`.
|
|
7
|
+
*
|
|
8
|
+
* MatTooltip creates its overlay component with `new ComponentPortal(component, this._viewContainerRef)`,
|
|
9
|
+
* so the CDK takes the `portal.viewContainerRef` branch of `attachComponentPortal` and skips
|
|
10
|
+
* `ApplicationRef.attachView`: only the DOM node is relocated to the overlay container, while the
|
|
11
|
+
* component itself stays a change-detection child of the view that hosts the trigger. MatTooltip then
|
|
12
|
+
* merely calls `markForCheck()` on it, twice:
|
|
13
|
+
*
|
|
14
|
+
* - in `_updateTooltipMessage()`, right after attaching — the message;
|
|
15
|
+
* - in `TooltipComponent._onShow()`, `showDelay` later — `_isMultiline`, which drives
|
|
16
|
+
* `mdc-tooltip--multiline` and therefore `text-align: left`.
|
|
17
|
+
*
|
|
18
|
+
* Neither reaches a detached subtree, so the tooltip opens EMPTY and, once text does appear, is
|
|
19
|
+
* centred until some unrelated check runs — a visible layout shift, or no text at all if the pointer
|
|
20
|
+
* is held still. Both were measured in a device table before this existed.
|
|
21
|
+
*
|
|
22
|
+
* `_viewContainerRef` and `_portal` are private in `_MatTooltipBase`, so the cause cannot be fixed
|
|
23
|
+
* from a subclass; the honest fix belongs upstream. What a subclass CAN do is force the checks that
|
|
24
|
+
* MatTooltip only requests. Hooking `show()` — rather than a hover event — is what makes this
|
|
25
|
+
* reliable: `super.show()` has attached the overlay and set the message by the time it returns, so
|
|
26
|
+
* there is no ordering to race. (A listener on an ancestor element loses that race unpredictably: the
|
|
27
|
+
* trigger's own `mouseenter` is a separate event dispatch.)
|
|
28
|
+
*
|
|
29
|
+
* Options are exposed with `aup`-prefixed aliases (`aupTooltipPosition`, `aupTooltipShowDelay`, …)
|
|
30
|
+
* alongside the inherited `matTooltip*` ones, e.g.
|
|
31
|
+
* `<span [aupTooltip]="text" aupTooltipPosition="above">`.
|
|
32
|
+
*/
|
|
33
|
+
export class AupTooltipDirective extends MatTooltip {
|
|
34
|
+
/**
|
|
35
|
+
* The very container MatTooltip inserts its overlay component into, so the inserted ViewRefs ARE the
|
|
36
|
+
* tooltip's views. Measured in a browser: after `super.show()` this holds exactly 1 view, and
|
|
37
|
+
* checking it turns the overlay's text from "" into the message. Preferred over the injected
|
|
38
|
+
* `ChangeDetectorRef` (which also works) because it targets the tooltip's own view rather than
|
|
39
|
+
* whichever enclosing view the node injector happens to resolve to.
|
|
40
|
+
*/
|
|
41
|
+
container = inject(ViewContainerRef);
|
|
42
|
+
show(delay = this.showDelay, origin) {
|
|
43
|
+
super.show(delay, origin);
|
|
44
|
+
// The message is already set on the instance, so this paints it immediately.
|
|
45
|
+
this.check();
|
|
46
|
+
// `_onShow()` cannot know the text wrapped until the box is on screen, so it measures and sets
|
|
47
|
+
// `_isMultiline` only after the delay. Check just past that point, which reproduces the
|
|
48
|
+
// single-frame reflow an attached view gets for free.
|
|
49
|
+
setTimeout(() => this.check(), delay + AupTooltipDirective.LAYOUT_CHECK_GRACE_MS);
|
|
50
|
+
}
|
|
51
|
+
check() {
|
|
52
|
+
for (let i = 0; i < this.container.length; i++) {
|
|
53
|
+
const view = this.container.get(i);
|
|
54
|
+
// Cells are recycled aggressively by a virtual-scroll table, and detectChanges() on a destroyed
|
|
55
|
+
// view throws.
|
|
56
|
+
if (view && !view.destroyed) {
|
|
57
|
+
view.detectChanges();
|
|
58
|
+
}
|
|
59
|
+
}
|
|
60
|
+
}
|
|
61
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.9", ngImport: i0, type: AupTooltipDirective, deps: null, target: i0.ɵɵFactoryTarget.Directive });
|
|
62
|
+
static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "16.2.9", type: AupTooltipDirective, selector: "[aupTooltip]", inputs: { message: ["aupTooltip", "message"], position: ["aupTooltipPosition", "position"], positionAtOrigin: ["aupTooltipPositionAtOrigin", "positionAtOrigin"], disabled: ["aupTooltipDisabled", "disabled"], showDelay: ["aupTooltipShowDelay", "showDelay"], hideDelay: ["aupTooltipHideDelay", "hideDelay"], touchGestures: ["aupTooltipTouchGestures", "touchGestures"], tooltipClass: ["aupTooltipClass", "tooltipClass"] }, exportAs: ["aupTooltip"], usesInheritance: true, ngImport: i0 });
|
|
63
|
+
}
|
|
64
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.9", ngImport: i0, type: AupTooltipDirective, decorators: [{
|
|
65
|
+
type: Directive,
|
|
66
|
+
args: [{
|
|
67
|
+
// eslint-disable-next-line @angular-eslint/directive-selector -- mirrors matTooltip's attribute form
|
|
68
|
+
selector: '[aupTooltip]',
|
|
69
|
+
exportAs: 'aupTooltip',
|
|
70
|
+
// `aup`-prefixed aliases onto MatTooltip's own properties, so a whole tooltip reads consistently
|
|
71
|
+
// (`[aupTooltip]="text" aupTooltipPosition="above"`) instead of mixing prefixes. The inherited
|
|
72
|
+
// `matTooltip*` aliases still work, so migrating a call site can be done one attribute at a time.
|
|
73
|
+
inputs: [
|
|
74
|
+
'message: aupTooltip',
|
|
75
|
+
'position: aupTooltipPosition',
|
|
76
|
+
'positionAtOrigin: aupTooltipPositionAtOrigin',
|
|
77
|
+
'disabled: aupTooltipDisabled',
|
|
78
|
+
'showDelay: aupTooltipShowDelay',
|
|
79
|
+
'hideDelay: aupTooltipHideDelay',
|
|
80
|
+
'touchGestures: aupTooltipTouchGestures',
|
|
81
|
+
'tooltipClass: aupTooltipClass'
|
|
82
|
+
]
|
|
83
|
+
}]
|
|
84
|
+
}] });
|
|
85
|
+
(function (AupTooltipDirective) {
|
|
86
|
+
/** Enough to land after `_onShow()` has set `_isMultiline`, small enough to be imperceptible. */
|
|
87
|
+
AupTooltipDirective.LAYOUT_CHECK_GRACE_MS = 20;
|
|
88
|
+
})(AupTooltipDirective || (AupTooltipDirective = {}));
|
|
89
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiYXVwLXRvb2x0aXAuZGlyZWN0aXZlLmpzIiwic291cmNlUm9vdCI6IiIsInNvdXJjZXMiOlsiLi4vLi4vLi4vLi4vLi4vLi4vbGlicy9hbmd1bGFyLXVpLXBvd2VydXBzL3NyYy9saWIvZGlyZWN0aXZlcy9hdXAtdG9vbHRpcC5kaXJlY3RpdmUudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IkFBQUEsT0FBTyxFQUFDLFNBQVMsRUFBRSxnQkFBZ0IsRUFBRSxNQUFNLEVBQUMsTUFBTSxlQUFlLENBQUM7QUFDbEUsT0FBTyxFQUFDLFVBQVUsRUFBQyxNQUFNLDJCQUEyQixDQUFDOztBQUVyRDs7Ozs7Ozs7Ozs7Ozs7Ozs7Ozs7Ozs7Ozs7OztHQTRCRztBQW1CSCxNQUFNLE9BQU8sbUJBQW9CLFNBQVEsVUFBVTtJQUVqRDs7Ozs7O09BTUc7SUFDYyxTQUFTLEdBQUcsTUFBTS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G9ydCBjb25zdCBMQVlPVVRfQ0hFQ0tfR1JBQ0VfTVMgPSAyMDtcbn1cbiJdfQ==
|
|
@@ -5,7 +5,9 @@ import { MatFormFieldModule } from '@angular/material/form-field';
|
|
|
5
5
|
import { MatInputModule } from '@angular/material/input';
|
|
6
6
|
import { MatSelectModule } from '@angular/material/select';
|
|
7
7
|
import { MatTabsModule } from '@angular/material/tabs';
|
|
8
|
+
import { MatTooltipModule } from '@angular/material/tooltip';
|
|
8
9
|
import { BrowserAnimationsModule } from '@angular/platform-browser/animations';
|
|
10
|
+
import { AupTooltipDirective } from './aup-tooltip.directive';
|
|
9
11
|
import { CommandDirective } from './command.directive';
|
|
10
12
|
import { FocusBindingDirective } from './focus-binding.directive';
|
|
11
13
|
import { GarbageCollectorDirective } from './garbage-collector.directive';
|
|
@@ -14,7 +16,8 @@ import { HighlightPipe } from './highlight.pipe';
|
|
|
14
16
|
import * as i0 from "@angular/core";
|
|
15
17
|
export class DirectivesModule {
|
|
16
18
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.9", ngImport: i0, type: DirectivesModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
|
|
17
|
-
static ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "16.2.9", ngImport: i0, type: DirectivesModule, declarations: [
|
|
19
|
+
static ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "16.2.9", ngImport: i0, type: DirectivesModule, declarations: [AupTooltipDirective,
|
|
20
|
+
CommandDirective,
|
|
18
21
|
FocusBindingDirective,
|
|
19
22
|
HighlightPipe,
|
|
20
23
|
HighlightTextModelDirective,
|
|
@@ -24,7 +27,9 @@ export class DirectivesModule {
|
|
|
24
27
|
MatInputModule,
|
|
25
28
|
MatFormFieldModule,
|
|
26
29
|
MatSelectModule,
|
|
27
|
-
MatTabsModule
|
|
30
|
+
MatTabsModule,
|
|
31
|
+
MatTooltipModule], exports: [AupTooltipDirective,
|
|
32
|
+
CommandDirective,
|
|
28
33
|
FocusBindingDirective,
|
|
29
34
|
HighlightPipe,
|
|
30
35
|
HighlightTextModelDirective,
|
|
@@ -35,12 +40,14 @@ export class DirectivesModule {
|
|
|
35
40
|
MatInputModule,
|
|
36
41
|
MatFormFieldModule,
|
|
37
42
|
MatSelectModule,
|
|
38
|
-
MatTabsModule
|
|
43
|
+
MatTabsModule,
|
|
44
|
+
MatTooltipModule] });
|
|
39
45
|
}
|
|
40
46
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.9", ngImport: i0, type: DirectivesModule, decorators: [{
|
|
41
47
|
type: NgModule,
|
|
42
48
|
args: [{
|
|
43
49
|
declarations: [
|
|
50
|
+
AupTooltipDirective,
|
|
44
51
|
CommandDirective,
|
|
45
52
|
FocusBindingDirective,
|
|
46
53
|
HighlightPipe,
|
|
@@ -54,9 +61,11 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.9", ngImpor
|
|
|
54
61
|
MatInputModule,
|
|
55
62
|
MatFormFieldModule,
|
|
56
63
|
MatSelectModule,
|
|
57
|
-
MatTabsModule
|
|
64
|
+
MatTabsModule,
|
|
65
|
+
MatTooltipModule
|
|
58
66
|
],
|
|
59
67
|
exports: [
|
|
68
|
+
AupTooltipDirective,
|
|
60
69
|
CommandDirective,
|
|
61
70
|
FocusBindingDirective,
|
|
62
71
|
HighlightPipe,
|
|
@@ -65,4 +74,4 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.9", ngImpor
|
|
|
65
74
|
]
|
|
66
75
|
}]
|
|
67
76
|
}] });
|
|
68
|
-
//# sourceMappingURL=data:application/json;base64,
|
|
77
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiZGlyZWN0aXZlcy5tb2R1bGUuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi8uLi8uLi8uLi8uLi9saWJz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Uge1xufVxuIl19
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* @file Automatically generated by barrelsby.
|
|
3
3
|
*/
|
|
4
|
+
export * from "./aup-tooltip.directive";
|
|
4
5
|
export * from "./command.directive";
|
|
5
6
|
export * from "./directives.module";
|
|
6
7
|
export * from "./focus-binding-factory";
|
|
@@ -10,4 +11,4 @@ export * from "./garbage-collector.directive";
|
|
|
10
11
|
export * from "./highlight-text-model.directive";
|
|
11
12
|
export * from "./highlight.pipe";
|
|
12
13
|
export * from "./resize-observer.directive";
|
|
13
|
-
//# sourceMappingURL=data:application/json;base64,
|
|
14
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiZXhwb3J0cy5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbIi4uLy4uLy4uLy4uLy4uLy4uL2xpYnMvYW5ndWxhci11aS1wb3dlcnVwcy9zcmMvbGliL2RpcmVjdGl2ZXMvZXhwb3J0cy50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiQUFBQTs7R0FFRztBQUVILGNBQWMseUJBQXlCLENBQUM7QUFDeEMsY0FBYyxxQkFBcUIsQ0FBQztBQUNwQyxjQUFjLHFCQUFxQixDQUFDO0FBQ3BDLGNBQWMseUJBQXlCLENBQUM7QUFDeEMsY0FBYywyQkFBMkIsQ0FBQztBQUMxQyxjQUFjLGlCQUFpQixDQUFDO0FBQ2hDLGNBQWMsK0JBQStCLENBQUM7QUFDOUMsY0FBYyxrQ0FBa0MsQ0FBQztBQUNqRCxjQUFjLGtCQUFrQixDQUFDO0FBQ2pDLGNBQWMsNkJBQTZCLENBQUMiLCJzb3VyY2VzQ29udGVudCI6WyIvKipcbiAqIEBmaWxlIEF1dG9tYXRpY2FsbHkgZ2VuZXJhdGVkIGJ5IGJhcnJlbHNieS5cbiAqL1xuXG5leHBvcnQgKiBmcm9tIFwiLi9hdXAtdG9vbHRpcC5kaXJlY3RpdmVcIjtcbmV4cG9ydCAqIGZyb20gXCIuL2NvbW1hbmQuZGlyZWN0aXZlXCI7XG5leHBvcnQgKiBmcm9tIFwiLi9kaXJlY3RpdmVzLm1vZHVsZVwiO1xuZXhwb3J0ICogZnJvbSBcIi4vZm9jdXMtYmluZGluZy1mYWN0b3J5XCI7XG5leHBvcnQgKiBmcm9tIFwiLi9mb2N1cy1iaW5kaW5nLmRpcmVjdGl2ZVwiO1xuZXhwb3J0ICogZnJvbSBcIi4vZm9jdXMtYmluZGluZ1wiO1xuZXhwb3J0ICogZnJvbSBcIi4vZ2FyYmFnZS1jb2xsZWN0b3IuZGlyZWN0aXZlXCI7XG5leHBvcnQgKiBmcm9tIFwiLi9oaWdobGlnaHQtdGV4dC1tb2RlbC5kaXJlY3RpdmVcIjtcbmV4cG9ydCAqIGZyb20gXCIuL2hpZ2hsaWdodC5waXBlXCI7XG5leHBvcnQgKiBmcm9tIFwiLi9yZXNpemUtb2JzZXJ2ZXIuZGlyZWN0aXZlXCI7XG4iXX0=
|
|
@@ -2,7 +2,7 @@ import { ObserversModule } from '@angular/cdk/observers';
|
|
|
2
2
|
import * as i1$1 from '@angular/common';
|
|
3
3
|
import { DOCUMENT, CommonModule } from '@angular/common';
|
|
4
4
|
import * as i0 from '@angular/core';
|
|
5
|
-
import {
|
|
5
|
+
import { inject, ViewContainerRef, Directive, ElementRef, Inject, Host, Optional, Input, HostListener, InjectionToken, ChangeDetectorRef, NgZone, Injectable, Pipe, NgModule, Component, ContentChild, HostBinding, ChangeDetectionStrategy, ViewEncapsulation, ViewChild, ViewChildren, EventEmitter, Output, Self, ContentChildren, ComponentRef, Injector, PLATFORM_ID, SkipSelf } from '@angular/core';
|
|
6
6
|
import * as i2$5 from '@angular/forms';
|
|
7
7
|
import { FormsModule } from '@angular/forms';
|
|
8
8
|
import * as i4 from '@angular/material/form-field';
|
|
@@ -37,7 +37,7 @@ import { MatProgressSpinnerModule } from '@angular/material/progress-spinner';
|
|
|
37
37
|
import * as i2$7 from '@angular/material/table';
|
|
38
38
|
import { MatTableModule } from '@angular/material/table';
|
|
39
39
|
import * as i3 from '@angular/material/tooltip';
|
|
40
|
-
import { MatTooltipModule } from '@angular/material/tooltip';
|
|
40
|
+
import { MatTooltip, MatTooltipModule } from '@angular/material/tooltip';
|
|
41
41
|
import * as i4$2 from 'ng-table-virtual-scroll';
|
|
42
42
|
import { TableVirtualScrollDataSource, TableVirtualScrollModule } from 'ng-table-virtual-scroll';
|
|
43
43
|
import * as i1$3 from '@coolon/pectin';
|
|
@@ -66,6 +66,92 @@ import { MatCardModule } from '@angular/material/card';
|
|
|
66
66
|
import * as i3$4 from '@angular/material/list';
|
|
67
67
|
import { MatListModule } from '@angular/material/list';
|
|
68
68
|
|
|
69
|
+
/**
|
|
70
|
+
* `matTooltip` that also renders inside a detached change-detection subtree — i.e. inside an
|
|
71
|
+
* `aup-table` body with `AUP_TABLE_OPTIMIZED_CHANGE_DETECTION`.
|
|
72
|
+
*
|
|
73
|
+
* MatTooltip creates its overlay component with `new ComponentPortal(component, this._viewContainerRef)`,
|
|
74
|
+
* so the CDK takes the `portal.viewContainerRef` branch of `attachComponentPortal` and skips
|
|
75
|
+
* `ApplicationRef.attachView`: only the DOM node is relocated to the overlay container, while the
|
|
76
|
+
* component itself stays a change-detection child of the view that hosts the trigger. MatTooltip then
|
|
77
|
+
* merely calls `markForCheck()` on it, twice:
|
|
78
|
+
*
|
|
79
|
+
* - in `_updateTooltipMessage()`, right after attaching — the message;
|
|
80
|
+
* - in `TooltipComponent._onShow()`, `showDelay` later — `_isMultiline`, which drives
|
|
81
|
+
* `mdc-tooltip--multiline` and therefore `text-align: left`.
|
|
82
|
+
*
|
|
83
|
+
* Neither reaches a detached subtree, so the tooltip opens EMPTY and, once text does appear, is
|
|
84
|
+
* centred until some unrelated check runs — a visible layout shift, or no text at all if the pointer
|
|
85
|
+
* is held still. Both were measured in a device table before this existed.
|
|
86
|
+
*
|
|
87
|
+
* `_viewContainerRef` and `_portal` are private in `_MatTooltipBase`, so the cause cannot be fixed
|
|
88
|
+
* from a subclass; the honest fix belongs upstream. What a subclass CAN do is force the checks that
|
|
89
|
+
* MatTooltip only requests. Hooking `show()` — rather than a hover event — is what makes this
|
|
90
|
+
* reliable: `super.show()` has attached the overlay and set the message by the time it returns, so
|
|
91
|
+
* there is no ordering to race. (A listener on an ancestor element loses that race unpredictably: the
|
|
92
|
+
* trigger's own `mouseenter` is a separate event dispatch.)
|
|
93
|
+
*
|
|
94
|
+
* Options are exposed with `aup`-prefixed aliases (`aupTooltipPosition`, `aupTooltipShowDelay`, …)
|
|
95
|
+
* alongside the inherited `matTooltip*` ones, e.g.
|
|
96
|
+
* `<span [aupTooltip]="text" aupTooltipPosition="above">`.
|
|
97
|
+
*/
|
|
98
|
+
class AupTooltipDirective extends MatTooltip {
|
|
99
|
+
/**
|
|
100
|
+
* The very container MatTooltip inserts its overlay component into, so the inserted ViewRefs ARE the
|
|
101
|
+
* tooltip's views. Measured in a browser: after `super.show()` this holds exactly 1 view, and
|
|
102
|
+
* checking it turns the overlay's text from "" into the message. Preferred over the injected
|
|
103
|
+
* `ChangeDetectorRef` (which also works) because it targets the tooltip's own view rather than
|
|
104
|
+
* whichever enclosing view the node injector happens to resolve to.
|
|
105
|
+
*/
|
|
106
|
+
container = inject(ViewContainerRef);
|
|
107
|
+
show(delay = this.showDelay, origin) {
|
|
108
|
+
super.show(delay, origin);
|
|
109
|
+
// The message is already set on the instance, so this paints it immediately.
|
|
110
|
+
this.check();
|
|
111
|
+
// `_onShow()` cannot know the text wrapped until the box is on screen, so it measures and sets
|
|
112
|
+
// `_isMultiline` only after the delay. Check just past that point, which reproduces the
|
|
113
|
+
// single-frame reflow an attached view gets for free.
|
|
114
|
+
setTimeout(() => this.check(), delay + AupTooltipDirective.LAYOUT_CHECK_GRACE_MS);
|
|
115
|
+
}
|
|
116
|
+
check() {
|
|
117
|
+
for (let i = 0; i < this.container.length; i++) {
|
|
118
|
+
const view = this.container.get(i);
|
|
119
|
+
// Cells are recycled aggressively by a virtual-scroll table, and detectChanges() on a destroyed
|
|
120
|
+
// view throws.
|
|
121
|
+
if (view && !view.destroyed) {
|
|
122
|
+
view.detectChanges();
|
|
123
|
+
}
|
|
124
|
+
}
|
|
125
|
+
}
|
|
126
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.9", ngImport: i0, type: AupTooltipDirective, deps: null, target: i0.ɵɵFactoryTarget.Directive });
|
|
127
|
+
static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "16.2.9", type: AupTooltipDirective, selector: "[aupTooltip]", inputs: { message: ["aupTooltip", "message"], position: ["aupTooltipPosition", "position"], positionAtOrigin: ["aupTooltipPositionAtOrigin", "positionAtOrigin"], disabled: ["aupTooltipDisabled", "disabled"], showDelay: ["aupTooltipShowDelay", "showDelay"], hideDelay: ["aupTooltipHideDelay", "hideDelay"], touchGestures: ["aupTooltipTouchGestures", "touchGestures"], tooltipClass: ["aupTooltipClass", "tooltipClass"] }, exportAs: ["aupTooltip"], usesInheritance: true, ngImport: i0 });
|
|
128
|
+
}
|
|
129
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.9", ngImport: i0, type: AupTooltipDirective, decorators: [{
|
|
130
|
+
type: Directive,
|
|
131
|
+
args: [{
|
|
132
|
+
// eslint-disable-next-line @angular-eslint/directive-selector -- mirrors matTooltip's attribute form
|
|
133
|
+
selector: '[aupTooltip]',
|
|
134
|
+
exportAs: 'aupTooltip',
|
|
135
|
+
// `aup`-prefixed aliases onto MatTooltip's own properties, so a whole tooltip reads consistently
|
|
136
|
+
// (`[aupTooltip]="text" aupTooltipPosition="above"`) instead of mixing prefixes. The inherited
|
|
137
|
+
// `matTooltip*` aliases still work, so migrating a call site can be done one attribute at a time.
|
|
138
|
+
inputs: [
|
|
139
|
+
'message: aupTooltip',
|
|
140
|
+
'position: aupTooltipPosition',
|
|
141
|
+
'positionAtOrigin: aupTooltipPositionAtOrigin',
|
|
142
|
+
'disabled: aupTooltipDisabled',
|
|
143
|
+
'showDelay: aupTooltipShowDelay',
|
|
144
|
+
'hideDelay: aupTooltipHideDelay',
|
|
145
|
+
'touchGestures: aupTooltipTouchGestures',
|
|
146
|
+
'tooltipClass: aupTooltipClass'
|
|
147
|
+
]
|
|
148
|
+
}]
|
|
149
|
+
}] });
|
|
150
|
+
(function (AupTooltipDirective) {
|
|
151
|
+
/** Enough to land after `_onShow()` has set `_isMultiline`, small enough to be imperceptible. */
|
|
152
|
+
AupTooltipDirective.LAYOUT_CHECK_GRACE_MS = 20;
|
|
153
|
+
})(AupTooltipDirective || (AupTooltipDirective = {}));
|
|
154
|
+
|
|
69
155
|
/* eslint-disable @typescript-eslint/no-explicit-any -- command directive accepts arbitrary command shapes */
|
|
70
156
|
class CommandDirective extends GarbageCollector {
|
|
71
157
|
elementRef;
|
|
@@ -607,7 +693,8 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.9", ngImpor
|
|
|
607
693
|
|
|
608
694
|
class DirectivesModule {
|
|
609
695
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.9", ngImport: i0, type: DirectivesModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
|
|
610
|
-
static ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "16.2.9", ngImport: i0, type: DirectivesModule, declarations: [
|
|
696
|
+
static ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "16.2.9", ngImport: i0, type: DirectivesModule, declarations: [AupTooltipDirective,
|
|
697
|
+
CommandDirective,
|
|
611
698
|
FocusBindingDirective,
|
|
612
699
|
HighlightPipe,
|
|
613
700
|
HighlightTextModelDirective,
|
|
@@ -617,7 +704,9 @@ class DirectivesModule {
|
|
|
617
704
|
MatInputModule,
|
|
618
705
|
MatFormFieldModule,
|
|
619
706
|
MatSelectModule,
|
|
620
|
-
MatTabsModule
|
|
707
|
+
MatTabsModule,
|
|
708
|
+
MatTooltipModule], exports: [AupTooltipDirective,
|
|
709
|
+
CommandDirective,
|
|
621
710
|
FocusBindingDirective,
|
|
622
711
|
HighlightPipe,
|
|
623
712
|
HighlightTextModelDirective,
|
|
@@ -628,12 +717,14 @@ class DirectivesModule {
|
|
|
628
717
|
MatInputModule,
|
|
629
718
|
MatFormFieldModule,
|
|
630
719
|
MatSelectModule,
|
|
631
|
-
MatTabsModule
|
|
720
|
+
MatTabsModule,
|
|
721
|
+
MatTooltipModule] });
|
|
632
722
|
}
|
|
633
723
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.9", ngImport: i0, type: DirectivesModule, decorators: [{
|
|
634
724
|
type: NgModule,
|
|
635
725
|
args: [{
|
|
636
726
|
declarations: [
|
|
727
|
+
AupTooltipDirective,
|
|
637
728
|
CommandDirective,
|
|
638
729
|
FocusBindingDirective,
|
|
639
730
|
HighlightPipe,
|
|
@@ -647,9 +738,11 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.9", ngImpor
|
|
|
647
738
|
MatInputModule,
|
|
648
739
|
MatFormFieldModule,
|
|
649
740
|
MatSelectModule,
|
|
650
|
-
MatTabsModule
|
|
741
|
+
MatTabsModule,
|
|
742
|
+
MatTooltipModule
|
|
651
743
|
],
|
|
652
744
|
exports: [
|
|
745
|
+
AupTooltipDirective,
|
|
653
746
|
CommandDirective,
|
|
654
747
|
FocusBindingDirective,
|
|
655
748
|
HighlightPipe,
|
|
@@ -5012,9 +5105,6 @@ class TableCellComponent extends DisposableComponent {
|
|
|
5012
5105
|
defaultClassNames = 'aup-cell-renderer';
|
|
5013
5106
|
fillCell = false;
|
|
5014
5107
|
padChild = false;
|
|
5015
|
-
// Nil unless an ancestor aup-table-body opted into detached change detection, which is exactly
|
|
5016
|
-
// when the problem refreshOverlaysOnHover() solves can occur.
|
|
5017
|
-
detachedParentCdr = this.inject(AUP_DETACHED_PARENT_CDR, { optional: true, skipSelf: true });
|
|
5018
5108
|
constructor() {
|
|
5019
5109
|
super();
|
|
5020
5110
|
this.onInit(() => {
|
|
@@ -5036,42 +5126,8 @@ class TableCellComponent extends DisposableComponent {
|
|
|
5036
5126
|
row: this.row,
|
|
5037
5127
|
};
|
|
5038
5128
|
}
|
|
5039
|
-
/**
|
|
5040
|
-
* A CDK overlay attached through a `ComponentPortal` carrying a `ViewContainerRef` — MatTooltip is
|
|
5041
|
-
* the common case — creates its component in the TRIGGER's view container: `attachComponentPortal`
|
|
5042
|
-
* takes the `portal.viewContainerRef` branch and skips `ApplicationRef.attachView`, so only the DOM
|
|
5043
|
-
* node is relocated to the overlay container. The component stays a change-detection child of THIS
|
|
5044
|
-
* cell's view, which `aup-table-body` has detached. MatTooltip only calls `markForCheck()` on it,
|
|
5045
|
-
* and nothing sweeps a detached subtree, so the tooltip paints EMPTY. `mouseleave` tears the
|
|
5046
|
-
* overlay down, so every RE-hover rebuilds a component that needs a fresh check — which is why the
|
|
5047
|
-
* first hover of a cell can look fine and later ones don't.
|
|
5048
|
-
*
|
|
5049
|
-
* The deferral is the whole trick, and it must be a MACROTASK. `mouseenter` is dispatched as a
|
|
5050
|
-
* separate event per entered element, outermost first, so this cell's listener runs in an earlier
|
|
5051
|
-
* task than the trigger's — a `queueMicrotask` check drains before MatTooltip has even created the
|
|
5052
|
-
* overlay and is measurably a no-op (that is also why `markForCheck()`, which schedules a
|
|
5053
|
-
* microtask parent sweep, does not fix this).
|
|
5054
|
-
*
|
|
5055
|
-
* Scoped to this cell rather than routed through `DisposableComponent.scheduleParentSweep`: both
|
|
5056
|
-
* are correct once the timing is right, but the sweep only coalesces within a single microtask, and
|
|
5057
|
-
* each `mouseenter` is its own task — so it degenerates into one whole-table-body check per cell
|
|
5058
|
-
* entered, where this is one check of a single cell's view.
|
|
5059
|
-
*
|
|
5060
|
-
* `mouseenter` does not bubble, so this is one event per cell entered; it no-ops entirely for
|
|
5061
|
-
* tables that never detached.
|
|
5062
|
-
*/
|
|
5063
|
-
refreshOverlaysOnHover() {
|
|
5064
|
-
if (!this.detachedParentCdr) {
|
|
5065
|
-
return;
|
|
5066
|
-
}
|
|
5067
|
-
setTimeout(() => {
|
|
5068
|
-
if (!this.isDisposed()) {
|
|
5069
|
-
this.cdr.detectChanges();
|
|
5070
|
-
}
|
|
5071
|
-
});
|
|
5072
|
-
}
|
|
5073
5129
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.9", ngImport: i0, type: TableCellComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
5074
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "16.2.9", type: TableCellComponent, selector: "aup-table-cell", inputs: { row: "row", column: "column", tableModel: "tableModel" }, host: {
|
|
5130
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "16.2.9", type: TableCellComponent, selector: "aup-table-cell", inputs: { row: "row", column: "column", tableModel: "tableModel" }, host: { properties: { "class": "this.defaultClassNames", "class.fillCell": "this.fillCell", "class.padChild": "this.padChild" } }, usesInheritance: true, usesOnChanges: true, ngImport: i0, template: "<ng-container [cdkPortalOutlet]=\"getRendererPortal()\" (attached)=\"initialiseRenderer($event)\"></ng-container>\n", styles: [""], dependencies: [{ kind: "directive", type: i1$4.CdkPortalOutlet, selector: "[cdkPortalOutlet]", inputs: ["cdkPortalOutlet"], outputs: ["attached"], exportAs: ["cdkPortalOutlet"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
5075
5131
|
}
|
|
5076
5132
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.9", ngImport: i0, type: TableCellComponent, decorators: [{
|
|
5077
5133
|
type: Component,
|
|
@@ -5091,9 +5147,6 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.9", ngImpor
|
|
|
5091
5147
|
}], padChild: [{
|
|
5092
5148
|
type: HostBinding,
|
|
5093
5149
|
args: ['class.padChild']
|
|
5094
|
-
}], refreshOverlaysOnHover: [{
|
|
5095
|
-
type: HostListener,
|
|
5096
|
-
args: ['mouseenter']
|
|
5097
5150
|
}] } });
|
|
5098
5151
|
|
|
5099
5152
|
class TableHeaderCellComponent {
|
|
@@ -13707,5 +13760,5 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.9", ngImpor
|
|
|
13707
13760
|
* Generated bundle index. Do not edit.
|
|
13708
13761
|
*/
|
|
13709
13762
|
|
|
13710
|
-
export { ACTIVITY_DATA, ALERT_CONFIG, AUP_DETACHED_PARENT_CDR, AUP_PLACE_CONFIG, AUP_TABLE_OPTIMIZED_CHANGE_DETECTION, AUP_TABLE_VIRTUAL_SCROLL_BUFFER_MULTIPLIER, AUP_UNAUTHORISED_PLACE_NOTICE_COMPONENT, AbstractActivityTriggerComponent, AbstractCardContainerComponent, AbstractCellRenderer, AbstractConfirmDialogComponent, AbstractDialogComponent, AbstractInputComponent, AbstractInteractionContext, AbstractListInputComponent, AbstractPlaceNavigationComponent, AbstractPopStateNavigation, AbstractPopupMenuComponent, AbstractTableComponent, AbstractTableModel, AbstractValueInputComponent, Activity, ActivityActionsComponent, ActivityBodyComponent, ActivityContainerComponent, ActivityContext, ActivityOutletComponent, ActivityRef, ActivityTitleComponent, AddCardActivityComponent, AddItemInteractionContextComponent, Alert, AlertDialogComponent, AlertRendererComponent, AngularUiPowerupsModule, AutocompleteInputComponent, Bounds, BusyOverlayComponent, ButtonRendererComponent, CELL_RENDERER_PORTAL, CardContainerComponent, CellFooterPortalRef, CellHeaderPortalRef, CellPortalRef, CellRendererPortalRef, CheckboxInputComponent, ColumnManager, ColumnModel, ColumnOrderManager, ColumnTemplateDirective, ColumnTextSearchFormatter, CommandComponent, CommandContainer, CommandDirective, CommandFace, CommandFaceComponent, ComponentCellRendererPortalRef, ComponentsModule, Confirm, ConfirmRendererComponent, ConfirmThenDialogComponent, ConfirmThenExecuteDialogComponent, ConfirmationDialogComponent, ConsolidatedParameterMap, CustomTemplateColumnModel, CustomValueColumnModel, DEFINITION_META_DATA_KEY, DIALOG_INTERACTION_SERVICE_DEFAULTS, DecoratedTreeNode, DefaultCellRendererComponent, DefaultHeaderCellRendererComponent, DialogInteractionContext, DialogInteractionContextFactory, Dimension, DirectivesModule, DisposableComponent, EmptyStateComponent, EnableCellTextSearch, EventCleanUpSession, FOOTER_CELL_RENDERER_PORTAL, FileDownloadComponent, FlattenedTreeListModel, FlexComponent, FocusBinding, FocusBindingDirective, FocusBindingFactory, FocusContainerComponent, FocusableComponent, FooterRowCellsBuilder, FooterRowModel, Formatter, GarbageCollectorDirective, HEADER_CELL_RENDERER_PORTAL, HighlightPipe, HighlightTextModelDirective, HorizontalAlignment, INTERACTION_CONTEXT, IconComponent, InPlaceInteractionContextComponent, InlineActivityTriggerComponent, InlineEditorModel, InlineStringEditorComponent, InputActivity, InteractionContextProvider, InteractionContextTriggerForDirective, InteractionModule, InteractionService, InteractionServiceRoutingAdapter, Keys, LEFT_RIGHT_PLACE_ANIMATION, LabelledValueComponent, ListPlaceNavComponent, ListPropertyColumnModel, LoadableComponent, LoadingContainerComponent, MarkdownComponent, MarkdownService, ModalActivityTriggerComponent, ModalInteractionContextFactory, MoreMenuComponent, MultipleSelectInputComponent, Navigating, NavigatingDuringInteraction, NavigationContext, NavigationSession, NoopAuthGuard, NoopComponent, NotAuthorisedNoticeComponent, NumberInputComponent, POPUP_CONTAINER, PORTAL_RENDERER_COMPONENT, PaginatorComponent, ParameterDefinition, ParameterSanitiser, PasswordInputComponent, Place, PlaceAccessGuard, PlaceAuthService, PlaceComponent, PlaceComponentDeactivationHandler, PlaceDefinition, PlaceGuard, PlaceHistory, PlaceModule, PlaceOutletComponent, PlaceRouter, Point, PopStateDuringInteractionNavigation, PopStateNavigation, PopupActivityTriggerComponent, PopupAwareComponent, PopupInteractionContextComponent, PopupMenuComponent, PopupMenuRendererComponent, PropertyColumnModel, ROUTE_PARAMETER_LIST_KEY, RemoveLastInteractionFromUrlNavigationSession, ResizeAwareComponent, ResizeObserverDirective, RouteId, ScrollContainerComponent, SearchInputComponent, SectionHeaderComponent, SelectInputActivity, SelectInputComponent, SelectionCellComponent, SelectionColumnModel, SelectionHeaderCellComponent, SeparatorComponent, SidePlaceNavigationComponent, SlideDownInteractionContextComponent, StringInputActivity, StringInputComponent, SwitchCaseComponent, SwitchCaseDefaultDirective, SwitchCaseOption, SwitchCaseWhenDirective, SynchroniseInteractionContextIdsWithRoute, TabbedPlaceNavigationComponent, TableActionColumnComponent, TableBodyComponent, TableCellComponent, TableComponent, TableCustomMoreMenuComponent, TableCustomMoreMenuPopupComponent, TableFilterModel, TableFooterRow, TableHeaderCellComponent, TableModel, TableRowAttributesDirective, TemplateCellRendererPortalRef, TextInputComponent, TextSearchContext, ToolBarComponent, Track, TreeExpansionModel, TreeInheritanceIconComponent, TreeLabelCellRendererComponent, TreeLabelColumnModel, TreeTableComponent, TreeTableModel, UrlService, UrlSnapshot, VerticalFocusContainerComponent, VisibilityService, Visit, VisitParameter, VisitParameterList, VisitSegment, VisitSegmentSanitiser, WaitUntilLeavingInteractionTransitionCancelled, WaitUntilLinkTriggeredNavigationInteractionCancellationTypeDetermined, WaitUntilPopStateDuringCanDeactivateInteractionFinishes, collapseOrphanSeparators, getPlaceDefinition, leftRightPlaceAnimation, markdownPillExtension, setPlaceDefinition, slideDownAndRightOnEnterAnimation, slideDownOnEnterAnimation, slideDownWhenOpenAnimation, slideRightOnEnterAnimation, treeNodeDecorator };
|
|
13763
|
+
export { ACTIVITY_DATA, ALERT_CONFIG, AUP_DETACHED_PARENT_CDR, AUP_PLACE_CONFIG, AUP_TABLE_OPTIMIZED_CHANGE_DETECTION, AUP_TABLE_VIRTUAL_SCROLL_BUFFER_MULTIPLIER, AUP_UNAUTHORISED_PLACE_NOTICE_COMPONENT, AbstractActivityTriggerComponent, AbstractCardContainerComponent, AbstractCellRenderer, AbstractConfirmDialogComponent, AbstractDialogComponent, AbstractInputComponent, AbstractInteractionContext, AbstractListInputComponent, AbstractPlaceNavigationComponent, AbstractPopStateNavigation, AbstractPopupMenuComponent, AbstractTableComponent, AbstractTableModel, AbstractValueInputComponent, Activity, ActivityActionsComponent, ActivityBodyComponent, ActivityContainerComponent, ActivityContext, ActivityOutletComponent, ActivityRef, ActivityTitleComponent, AddCardActivityComponent, AddItemInteractionContextComponent, Alert, AlertDialogComponent, AlertRendererComponent, AngularUiPowerupsModule, AupTooltipDirective, AutocompleteInputComponent, Bounds, BusyOverlayComponent, ButtonRendererComponent, CELL_RENDERER_PORTAL, CardContainerComponent, CellFooterPortalRef, CellHeaderPortalRef, CellPortalRef, CellRendererPortalRef, CheckboxInputComponent, ColumnManager, ColumnModel, ColumnOrderManager, ColumnTemplateDirective, ColumnTextSearchFormatter, CommandComponent, CommandContainer, CommandDirective, CommandFace, CommandFaceComponent, ComponentCellRendererPortalRef, ComponentsModule, Confirm, ConfirmRendererComponent, ConfirmThenDialogComponent, ConfirmThenExecuteDialogComponent, ConfirmationDialogComponent, ConsolidatedParameterMap, CustomTemplateColumnModel, CustomValueColumnModel, DEFINITION_META_DATA_KEY, DIALOG_INTERACTION_SERVICE_DEFAULTS, DecoratedTreeNode, DefaultCellRendererComponent, DefaultHeaderCellRendererComponent, DialogInteractionContext, DialogInteractionContextFactory, Dimension, DirectivesModule, DisposableComponent, EmptyStateComponent, EnableCellTextSearch, EventCleanUpSession, FOOTER_CELL_RENDERER_PORTAL, FileDownloadComponent, FlattenedTreeListModel, FlexComponent, FocusBinding, FocusBindingDirective, FocusBindingFactory, FocusContainerComponent, FocusableComponent, FooterRowCellsBuilder, FooterRowModel, Formatter, GarbageCollectorDirective, HEADER_CELL_RENDERER_PORTAL, HighlightPipe, HighlightTextModelDirective, HorizontalAlignment, INTERACTION_CONTEXT, IconComponent, InPlaceInteractionContextComponent, InlineActivityTriggerComponent, InlineEditorModel, InlineStringEditorComponent, InputActivity, InteractionContextProvider, InteractionContextTriggerForDirective, InteractionModule, InteractionService, InteractionServiceRoutingAdapter, Keys, LEFT_RIGHT_PLACE_ANIMATION, LabelledValueComponent, ListPlaceNavComponent, ListPropertyColumnModel, LoadableComponent, LoadingContainerComponent, MarkdownComponent, MarkdownService, ModalActivityTriggerComponent, ModalInteractionContextFactory, MoreMenuComponent, MultipleSelectInputComponent, Navigating, NavigatingDuringInteraction, NavigationContext, NavigationSession, NoopAuthGuard, NoopComponent, NotAuthorisedNoticeComponent, NumberInputComponent, POPUP_CONTAINER, PORTAL_RENDERER_COMPONENT, PaginatorComponent, ParameterDefinition, ParameterSanitiser, PasswordInputComponent, Place, PlaceAccessGuard, PlaceAuthService, PlaceComponent, PlaceComponentDeactivationHandler, PlaceDefinition, PlaceGuard, PlaceHistory, PlaceModule, PlaceOutletComponent, PlaceRouter, Point, PopStateDuringInteractionNavigation, PopStateNavigation, PopupActivityTriggerComponent, PopupAwareComponent, PopupInteractionContextComponent, PopupMenuComponent, PopupMenuRendererComponent, PropertyColumnModel, ROUTE_PARAMETER_LIST_KEY, RemoveLastInteractionFromUrlNavigationSession, ResizeAwareComponent, ResizeObserverDirective, RouteId, ScrollContainerComponent, SearchInputComponent, SectionHeaderComponent, SelectInputActivity, SelectInputComponent, SelectionCellComponent, SelectionColumnModel, SelectionHeaderCellComponent, SeparatorComponent, SidePlaceNavigationComponent, SlideDownInteractionContextComponent, StringInputActivity, StringInputComponent, SwitchCaseComponent, SwitchCaseDefaultDirective, SwitchCaseOption, SwitchCaseWhenDirective, SynchroniseInteractionContextIdsWithRoute, TabbedPlaceNavigationComponent, TableActionColumnComponent, TableBodyComponent, TableCellComponent, TableComponent, TableCustomMoreMenuComponent, TableCustomMoreMenuPopupComponent, TableFilterModel, TableFooterRow, TableHeaderCellComponent, TableModel, TableRowAttributesDirective, TemplateCellRendererPortalRef, TextInputComponent, TextSearchContext, ToolBarComponent, Track, TreeExpansionModel, TreeInheritanceIconComponent, TreeLabelCellRendererComponent, TreeLabelColumnModel, TreeTableComponent, TreeTableModel, UrlService, UrlSnapshot, VerticalFocusContainerComponent, VisibilityService, Visit, VisitParameter, VisitParameterList, VisitSegment, VisitSegmentSanitiser, WaitUntilLeavingInteractionTransitionCancelled, WaitUntilLinkTriggeredNavigationInteractionCancellationTypeDetermined, WaitUntilPopStateDuringCanDeactivateInteractionFinishes, collapseOrphanSeparators, getPlaceDefinition, leftRightPlaceAnimation, markdownPillExtension, setPlaceDefinition, slideDownAndRightOnEnterAnimation, slideDownOnEnterAnimation, slideDownWhenOpenAnimation, slideRightOnEnterAnimation, treeNodeDecorator };
|
|
13711
13764
|
//# sourceMappingURL=coolon-angular-ui-powerups.mjs.map
|