@ngneers/controls 0.0.1-pre1 → 0.0.1-pre2
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/LICENSE +21 -0
- package/fesm2022/ngneers-controls-accordion.mjs +194 -0
- package/fesm2022/ngneers-controls-accordion.mjs.map +1 -0
- package/fesm2022/ngneers-controls-api-ng.mjs +668 -0
- package/fesm2022/ngneers-controls-api-ng.mjs.map +1 -0
- package/fesm2022/ngneers-controls-api.mjs +256 -227
- package/fesm2022/ngneers-controls-api.mjs.map +1 -1
- package/fesm2022/ngneers-controls-avatar.mjs +70 -0
- package/fesm2022/ngneers-controls-avatar.mjs.map +1 -0
- package/fesm2022/ngneers-controls-base.mjs +397 -0
- package/fesm2022/ngneers-controls-base.mjs.map +1 -0
- package/fesm2022/ngneers-controls-breadcrumb.mjs +74 -0
- package/fesm2022/ngneers-controls-breadcrumb.mjs.map +1 -0
- package/fesm2022/ngneers-controls-button-group.mjs +51 -0
- package/fesm2022/ngneers-controls-button-group.mjs.map +1 -0
- package/fesm2022/ngneers-controls-button.mjs +62 -0
- package/fesm2022/ngneers-controls-button.mjs.map +1 -0
- package/fesm2022/ngneers-controls-calendar-time-C7UnIFzU.mjs +63 -0
- package/fesm2022/ngneers-controls-calendar-time-C7UnIFzU.mjs.map +1 -0
- package/fesm2022/ngneers-controls-calendar.mjs +468 -0
- package/fesm2022/ngneers-controls-calendar.mjs.map +1 -0
- package/fesm2022/ngneers-controls-checkbox.mjs +58 -0
- package/fesm2022/ngneers-controls-checkbox.mjs.map +1 -0
- package/fesm2022/ngneers-controls-chip.mjs +52 -0
- package/fesm2022/ngneers-controls-chip.mjs.map +1 -0
- package/fesm2022/ngneers-controls-defer.mjs +43 -0
- package/fesm2022/ngneers-controls-defer.mjs.map +1 -0
- package/fesm2022/ngneers-controls-dialog.mjs +329 -33
- package/fesm2022/ngneers-controls-dialog.mjs.map +1 -1
- package/fesm2022/ngneers-controls-directives.mjs +443 -0
- package/fesm2022/ngneers-controls-directives.mjs.map +1 -0
- package/fesm2022/ngneers-controls-drawer.mjs +232 -0
- package/fesm2022/ngneers-controls-drawer.mjs.map +1 -0
- package/fesm2022/ngneers-controls-edit-inplace.mjs +120 -0
- package/fesm2022/ngneers-controls-edit-inplace.mjs.map +1 -0
- package/fesm2022/ngneers-controls-filter.mjs +516 -0
- package/fesm2022/ngneers-controls-filter.mjs.map +1 -0
- package/fesm2022/ngneers-controls-i18n-de-CdTPeBiR.mjs +87 -0
- package/fesm2022/ngneers-controls-i18n-de-CdTPeBiR.mjs.map +1 -0
- package/fesm2022/ngneers-controls-i18n-en-Cfp2pOLY.mjs +87 -0
- package/fesm2022/ngneers-controls-i18n-en-Cfp2pOLY.mjs.map +1 -0
- package/fesm2022/ngneers-controls-i18n.mjs +57 -0
- package/fesm2022/ngneers-controls-i18n.mjs.map +1 -0
- package/fesm2022/ngneers-controls-icon-calendar-z5xA9wTT.mjs +4 -0
- package/fesm2022/ngneers-controls-icon-calendar-z5xA9wTT.mjs.map +1 -0
- package/fesm2022/ngneers-controls-icon-check-DdAQ9k-T.mjs +4 -0
- package/fesm2022/ngneers-controls-icon-check-DdAQ9k-T.mjs.map +1 -0
- package/fesm2022/ngneers-controls-icon-chevron_down-HO-z-xOr.mjs +4 -0
- package/fesm2022/ngneers-controls-icon-chevron_down-HO-z-xOr.mjs.map +1 -0
- package/fesm2022/ngneers-controls-icon-chevron_left-CC5psi16.mjs +4 -0
- package/fesm2022/ngneers-controls-icon-chevron_left-CC5psi16.mjs.map +1 -0
- package/fesm2022/ngneers-controls-icon-chevron_right-BRxlzx4G.mjs +4 -0
- package/fesm2022/ngneers-controls-icon-chevron_right-BRxlzx4G.mjs.map +1 -0
- package/fesm2022/ngneers-controls-icon-chevron_up-cqhPO7g2.mjs +4 -0
- package/fesm2022/ngneers-controls-icon-chevron_up-cqhPO7g2.mjs.map +1 -0
- package/fesm2022/ngneers-controls-icon-ellipsis-DXIGA1sk.mjs +4 -0
- package/fesm2022/ngneers-controls-icon-ellipsis-DXIGA1sk.mjs.map +1 -0
- package/fesm2022/ngneers-controls-icon-filter-oU7E6Xgr.mjs +4 -0
- package/fesm2022/ngneers-controls-icon-filter-oU7E6Xgr.mjs.map +1 -0
- package/fesm2022/ngneers-controls-icon-filter_solid-CqIKuR4N.mjs +4 -0
- package/fesm2022/ngneers-controls-icon-filter_solid-CqIKuR4N.mjs.map +1 -0
- package/fesm2022/ngneers-controls-icon-magnifying_glass-T4Hzbkig.mjs +4 -0
- package/fesm2022/ngneers-controls-icon-magnifying_glass-T4Hzbkig.mjs.map +1 -0
- package/fesm2022/ngneers-controls-icon-minus-oGDEFO4E.mjs +4 -0
- package/fesm2022/ngneers-controls-icon-minus-oGDEFO4E.mjs.map +1 -0
- package/fesm2022/ngneers-controls-icon-sort-CRD4tafz.mjs +4 -0
- package/fesm2022/ngneers-controls-icon-sort-CRD4tafz.mjs.map +1 -0
- package/fesm2022/ngneers-controls-icon-sort_down-DiFB1P6R.mjs +4 -0
- package/fesm2022/ngneers-controls-icon-sort_down-DiFB1P6R.mjs.map +1 -0
- package/fesm2022/ngneers-controls-icon-sort_up-Bq_q3hIi.mjs +4 -0
- package/fesm2022/ngneers-controls-icon-sort_up-Bq_q3hIi.mjs.map +1 -0
- package/fesm2022/ngneers-controls-icon-xmark-BZKZORiu.mjs +4 -0
- package/fesm2022/ngneers-controls-icon-xmark-BZKZORiu.mjs.map +1 -0
- package/fesm2022/ngneers-controls-icon.mjs +60 -18
- package/fesm2022/ngneers-controls-icon.mjs.map +1 -1
- package/fesm2022/ngneers-controls-inplace.mjs +107 -0
- package/fesm2022/ngneers-controls-inplace.mjs.map +1 -0
- package/fesm2022/ngneers-controls-input-field.mjs +141 -0
- package/fesm2022/ngneers-controls-input-field.mjs.map +1 -0
- package/fesm2022/ngneers-controls-input-mask.mjs +282 -0
- package/fesm2022/ngneers-controls-input-mask.mjs.map +1 -0
- package/fesm2022/ngneers-controls-input.mjs +69 -0
- package/fesm2022/ngneers-controls-input.mjs.map +1 -0
- package/fesm2022/ngneers-controls-item-view.mjs +441 -0
- package/fesm2022/ngneers-controls-item-view.mjs.map +1 -0
- package/fesm2022/ngneers-controls-list-box.mjs +157 -53
- package/fesm2022/ngneers-controls-list-box.mjs.map +1 -1
- package/fesm2022/ngneers-controls-menu.mjs +332 -0
- package/fesm2022/ngneers-controls-menu.mjs.map +1 -0
- package/fesm2022/ngneers-controls-message.mjs +29 -0
- package/fesm2022/ngneers-controls-message.mjs.map +1 -0
- package/fesm2022/ngneers-controls-paginator.mjs +111 -0
- package/fesm2022/ngneers-controls-paginator.mjs.map +1 -0
- package/fesm2022/ngneers-controls-popover.mjs +129 -40
- package/fesm2022/ngneers-controls-popover.mjs.map +1 -1
- package/fesm2022/ngneers-controls-progress.mjs +82 -0
- package/fesm2022/ngneers-controls-progress.mjs.map +1 -0
- package/fesm2022/ngneers-controls-scroller.mjs +155 -78
- package/fesm2022/ngneers-controls-scroller.mjs.map +1 -1
- package/fesm2022/ngneers-controls-select-button.mjs +55 -0
- package/fesm2022/ngneers-controls-select-button.mjs.map +1 -0
- package/fesm2022/ngneers-controls-select.mjs +313 -103
- package/fesm2022/ngneers-controls-select.mjs.map +1 -1
- package/fesm2022/ngneers-controls-slider.mjs +155 -0
- package/fesm2022/ngneers-controls-slider.mjs.map +1 -0
- package/fesm2022/ngneers-controls-spinner.mjs +169 -0
- package/fesm2022/ngneers-controls-spinner.mjs.map +1 -0
- package/fesm2022/ngneers-controls-splitter.mjs +717 -0
- package/fesm2022/ngneers-controls-splitter.mjs.map +1 -0
- package/fesm2022/ngneers-controls-switch.mjs +39 -0
- package/fesm2022/ngneers-controls-switch.mjs.map +1 -0
- package/fesm2022/ngneers-controls-table.mjs +379 -0
- package/fesm2022/ngneers-controls-table.mjs.map +1 -0
- package/fesm2022/ngneers-controls-tabs.mjs +287 -0
- package/fesm2022/ngneers-controls-tabs.mjs.map +1 -0
- package/fesm2022/ngneers-controls-tag.mjs +29 -0
- package/fesm2022/ngneers-controls-tag.mjs.map +1 -0
- package/fesm2022/ngneers-controls-toast.mjs +184 -0
- package/fesm2022/ngneers-controls-toast.mjs.map +1 -0
- package/fesm2022/ngneers-controls-toggle-button.mjs +65 -0
- package/fesm2022/ngneers-controls-toggle-button.mjs.map +1 -0
- package/fesm2022/ngneers-controls-tooltip.mjs +454 -0
- package/fesm2022/ngneers-controls-tooltip.mjs.map +1 -0
- package/fesm2022/ngneers-controls-utils-ng.mjs +227 -0
- package/fesm2022/ngneers-controls-utils-ng.mjs.map +1 -0
- package/fesm2022/ngneers-controls-utils.mjs +217 -60
- package/fesm2022/ngneers-controls-utils.mjs.map +1 -1
- package/fesm2022/ngneers-controls.mjs.map +1 -1
- package/package.json +167 -32
- package/types/ngneers-controls-accordion.d.ts +114 -0
- package/types/ngneers-controls-api-ng.d.ts +291 -0
- package/types/ngneers-controls-api.d.ts +99 -0
- package/types/ngneers-controls-avatar.d.ts +50 -0
- package/types/ngneers-controls-base.d.ts +166 -0
- package/types/ngneers-controls-breadcrumb.d.ts +86 -0
- package/types/ngneers-controls-button-group.d.ts +30 -0
- package/types/ngneers-controls-button.d.ts +34 -0
- package/types/ngneers-controls-calendar.d.ts +275 -0
- package/types/ngneers-controls-checkbox.d.ts +38 -0
- package/types/ngneers-controls-chip.d.ts +37 -0
- package/types/ngneers-controls-defer.d.ts +22 -0
- package/types/ngneers-controls-dialog.d.ts +218 -0
- package/types/ngneers-controls-directives.d.ts +146 -0
- package/types/ngneers-controls-drawer.d.ts +220 -0
- package/types/ngneers-controls-edit-inplace.d.ts +182 -0
- package/types/ngneers-controls-filter.d.ts +304 -0
- package/types/ngneers-controls-i18n.d.ts +108 -0
- package/types/ngneers-controls-icon.d.ts +74 -0
- package/types/ngneers-controls-inplace.d.ts +95 -0
- package/types/ngneers-controls-input-field.d.ts +159 -0
- package/types/ngneers-controls-input-mask.d.ts +83 -0
- package/types/ngneers-controls-input.d.ts +27 -0
- package/types/ngneers-controls-item-view.d.ts +211 -0
- package/types/ngneers-controls-list-box.d.ts +216 -0
- package/types/ngneers-controls-menu.d.ts +178 -0
- package/types/ngneers-controls-message.d.ts +19 -0
- package/types/ngneers-controls-paginator.d.ts +162 -0
- package/types/ngneers-controls-popover.d.ts +101 -0
- package/types/ngneers-controls-progress.d.ts +44 -0
- package/types/ngneers-controls-scroller.d.ts +137 -0
- package/types/ngneers-controls-select-button.d.ts +37 -0
- package/types/ngneers-controls-select.d.ts +314 -0
- package/types/ngneers-controls-slider.d.ts +53 -0
- package/types/ngneers-controls-spinner.d.ts +105 -0
- package/types/ngneers-controls-splitter.d.ts +391 -0
- package/types/ngneers-controls-switch.d.ts +18 -0
- package/types/ngneers-controls-table.d.ts +157 -0
- package/types/ngneers-controls-tabs.d.ts +106 -0
- package/types/ngneers-controls-tag.d.ts +19 -0
- package/types/ngneers-controls-toast.d.ts +70 -0
- package/types/ngneers-controls-toggle-button.d.ts +46 -0
- package/types/ngneers-controls-tooltip.d.ts +188 -0
- package/types/ngneers-controls-utils-ng.d.ts +57 -0
- package/types/ngneers-controls-utils.d.ts +130 -0
- package/api/index.d.ts +0 -134
- package/custom-types/index.d.ts +0 -7
- package/dialog/index.d.ts +0 -43
- package/fesm2022/ngneers-controls-custom-types.mjs +0 -4
- package/fesm2022/ngneers-controls-custom-types.mjs.map +0 -1
- package/fesm2022/ngneers-controls-form-field.mjs +0 -33
- package/fesm2022/ngneers-controls-form-field.mjs.map +0 -1
- package/fesm2022/ngneers-controls-lazy-cacher.mjs +0 -30
- package/fesm2022/ngneers-controls-lazy-cacher.mjs.map +0 -1
- package/fesm2022/ngneers-controls-text-field.mjs +0 -23
- package/fesm2022/ngneers-controls-text-field.mjs.map +0 -1
- package/form-field/index.d.ts +0 -19
- package/icon/index.d.ts +0 -30
- package/lazy-cacher/index.d.ts +0 -14
- package/list-box/index.d.ts +0 -58
- package/popover/index.d.ts +0 -41
- package/scroller/index.d.ts +0 -95
- package/select/index.d.ts +0 -86
- package/text-field/index.d.ts +0 -10
- package/utils/index.d.ts +0 -36
- /package/{index.d.ts → types/ngneers-controls.d.ts} +0 -0
|
@@ -0,0 +1,454 @@
|
|
|
1
|
+
import * as i0 from '@angular/core';
|
|
2
|
+
import { inject, ViewContainerRef, signal, input, computed, effect, TemplateRef, Directive, viewChild, DOCUMENT, ChangeDetectionStrategy, Component } from '@angular/core';
|
|
3
|
+
import { NGN_CONFIG, abortSignalOnDestroy, autoPositionElement, splitPlacement } from '@ngneers/controls/api/ng';
|
|
4
|
+
import { NgnBase, provideSelf, NgnPt } from '@ngneers/controls/base';
|
|
5
|
+
import { NgnDefer } from '@ngneers/controls/defer';
|
|
6
|
+
import { getTimeSpanMilliseconds, notNullish } from '@ngneers/controls/utils';
|
|
7
|
+
import { generateElementId, computedWithPrevious } from '@ngneers/controls/utils-ng';
|
|
8
|
+
import { tooltipControlTemplate } from '@ngneers/controls-themes/templates/tooltip';
|
|
9
|
+
|
|
10
|
+
const relativeAnchorElementPosition = {
|
|
11
|
+
name: 'relativeAnchorElementPosition',
|
|
12
|
+
async fn(state) {
|
|
13
|
+
const { placement, rects } = state;
|
|
14
|
+
const axis = getAxis(placement);
|
|
15
|
+
const axisSize = axis === 'x' ? 'width' : 'height';
|
|
16
|
+
return {
|
|
17
|
+
data: {
|
|
18
|
+
start: rects.reference[axis] - state[axis],
|
|
19
|
+
center: rects.reference[axis] + rects.reference[axisSize] / 2 - state[axis],
|
|
20
|
+
end: rects.reference[axis] + rects.reference[axisSize] - state[axis],
|
|
21
|
+
},
|
|
22
|
+
};
|
|
23
|
+
},
|
|
24
|
+
};
|
|
25
|
+
function getAxis(placement) {
|
|
26
|
+
switch (placement.split('-')[0]) {
|
|
27
|
+
case 'top':
|
|
28
|
+
case 'bottom':
|
|
29
|
+
return 'x';
|
|
30
|
+
case 'left':
|
|
31
|
+
case 'right':
|
|
32
|
+
return 'y';
|
|
33
|
+
default:
|
|
34
|
+
throw new Error(`Unknown placement: ${placement}`);
|
|
35
|
+
}
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
/**
|
|
39
|
+
* @category control
|
|
40
|
+
*/
|
|
41
|
+
class NgnTooltip extends NgnBase {
|
|
42
|
+
theme = null;
|
|
43
|
+
_viewContainerRef = inject(ViewContainerRef);
|
|
44
|
+
_config = inject(NGN_CONFIG);
|
|
45
|
+
_tooltip = signal(null, ...(ngDevMode ? [{ debugName: "_tooltip" }] : []));
|
|
46
|
+
/**
|
|
47
|
+
* The content of the tooltip, can be a string or a TemplateRef.
|
|
48
|
+
* If the value is falsy, the tooltip will not be shown.
|
|
49
|
+
* @alias ngnTooltip
|
|
50
|
+
*/
|
|
51
|
+
content = input(null, { ...(ngDevMode ? { debugName: "content" } : {}), alias: 'ngnTooltip' });
|
|
52
|
+
/**
|
|
53
|
+
* The CSS class to apply to the tooltip.
|
|
54
|
+
* This can be used to apply custom styles to the tooltip.
|
|
55
|
+
* @alias ngnTooltipStyleClass
|
|
56
|
+
*/
|
|
57
|
+
styleClass = input(null, { ...(ngDevMode ? { debugName: "styleClass" } : {}), alias: 'ngnTooltipStyleClass' });
|
|
58
|
+
/**
|
|
59
|
+
* If set to `true`, the tooltip will only be shown if the anchor element is truncated. `""` is equivalent to `true`.
|
|
60
|
+
* @alias ngnTooltipShowOnlyIfTruncated
|
|
61
|
+
* @default false
|
|
62
|
+
*/
|
|
63
|
+
showOnlyIfTruncated = input(false, { ...(ngDevMode ? { debugName: "showOnlyIfTruncated" } : {}), alias: 'ngnTooltipShowOnlyIfTruncated' });
|
|
64
|
+
/**
|
|
65
|
+
* The size constraints for the tooltip.
|
|
66
|
+
* This can be used to limit the width and height of the tooltip.
|
|
67
|
+
* If not provided, the tooltip is only constrained by the size of the screen.
|
|
68
|
+
* @alias ngnTooltipSize
|
|
69
|
+
*/
|
|
70
|
+
size = input(null, { ...(ngDevMode ? { debugName: "size" } : {}), alias: 'ngnTooltipSize' });
|
|
71
|
+
/**
|
|
72
|
+
* The options for the tooltip.
|
|
73
|
+
* This is a shorthand for setting multiple options at once.
|
|
74
|
+
* The individual options take precedence over the options set here.
|
|
75
|
+
* @alias ngnTooltipOptions
|
|
76
|
+
*/
|
|
77
|
+
options = input(null, { ...(ngDevMode ? { debugName: "options" } : {}), alias: 'ngnTooltipOptions' });
|
|
78
|
+
/**
|
|
79
|
+
* The placement of the tooltip relative to the anchor element.
|
|
80
|
+
* @alias ngnTooltipPlacement
|
|
81
|
+
* @default 'bottom'
|
|
82
|
+
*/
|
|
83
|
+
placement = input(null, { ...(ngDevMode ? { debugName: "placement" } : {}), alias: 'ngnTooltipPlacement' });
|
|
84
|
+
/**
|
|
85
|
+
* The offset in Pixels of the tooltip from the anchor element.
|
|
86
|
+
* @alias ngnTooltipOffset
|
|
87
|
+
* @default 4
|
|
88
|
+
*/
|
|
89
|
+
offset = input(null, { ...(ngDevMode ? { debugName: "offset" } : {}), alias: 'ngnTooltipOffset' });
|
|
90
|
+
/**
|
|
91
|
+
* The delay before the tooltip is shown. If a number is provided, it is interpreted as milliseconds.
|
|
92
|
+
* @alias ngnTooltipShowDelay
|
|
93
|
+
* @default '0.5s'
|
|
94
|
+
*/
|
|
95
|
+
showDelay = input(null, { ...(ngDevMode ? { debugName: "showDelay" } : {}), alias: 'ngnTooltipShowDelay' });
|
|
96
|
+
/**
|
|
97
|
+
* The delay before the tooltip is hidden. If a number is provided, it is interpreted as milliseconds.
|
|
98
|
+
* @alias ngnTooltipHideDelay
|
|
99
|
+
* @default '0.1s'
|
|
100
|
+
*/
|
|
101
|
+
hideDelay = input(null, { ...(ngDevMode ? { debugName: "hideDelay" } : {}), alias: 'ngnTooltipHideDelay' });
|
|
102
|
+
/**
|
|
103
|
+
* Whether to show an arrow pointing to the anchor element. `""` is equivalent to `true`.
|
|
104
|
+
* @alias ngnTooltipShowArrow
|
|
105
|
+
* @default true
|
|
106
|
+
*/
|
|
107
|
+
showArrow = input(null, { ...(ngDevMode ? { debugName: "showArrow" } : {}), alias: 'ngnTooltipShowArrow' });
|
|
108
|
+
/**
|
|
109
|
+
* Shows the tooltip on hover.
|
|
110
|
+
* @alias ngnTooltipShowOnHover
|
|
111
|
+
* @default true
|
|
112
|
+
*/
|
|
113
|
+
showOnHover = input(null, { ...(ngDevMode ? { debugName: "showOnHover" } : {}), alias: 'ngnTooltipShowOnHover' });
|
|
114
|
+
/**
|
|
115
|
+
* Shows the tooltip on focus.
|
|
116
|
+
* @alias ngnTooltipShowOnFocus
|
|
117
|
+
* @default true
|
|
118
|
+
*/
|
|
119
|
+
showOnFocus = input(null, { ...(ngDevMode ? { debugName: "showOnFocus" } : {}), alias: 'ngnTooltipShowOnFocus' });
|
|
120
|
+
/**
|
|
121
|
+
* Hides the tooltip (without delay) when the mouse hovers over the tooltip.
|
|
122
|
+
* @alias ngnTooltipHideOnTooltipHover
|
|
123
|
+
* @default false
|
|
124
|
+
*/
|
|
125
|
+
hideOnTooltipHover = input(null, { ...(ngDevMode ? { debugName: "hideOnTooltipHover" } : {}), alias: 'ngnTooltipHideOnTooltipHover' });
|
|
126
|
+
/**
|
|
127
|
+
* Hides the tooltip (without delay) when the user clicks on the tooltip.
|
|
128
|
+
* @alias ngnTooltipHideOnClick
|
|
129
|
+
* @default true
|
|
130
|
+
*/
|
|
131
|
+
hideOnClick = input(null, { ...(ngDevMode ? { debugName: "hideOnClick" } : {}), alias: 'ngnTooltipHideOnClick' });
|
|
132
|
+
effectiveOptions = computed(() => {
|
|
133
|
+
const defaults = this._config.defaults.tooltip;
|
|
134
|
+
return {
|
|
135
|
+
placement: this.placement() ?? this.options()?.placement ?? defaults.placement,
|
|
136
|
+
offset: this.offset() ?? this.options()?.offset ?? defaults.offset,
|
|
137
|
+
showDelay: this.showDelay() ?? this.options()?.showDelay ?? defaults.showDelay,
|
|
138
|
+
hideDelay: this.hideDelay() ?? this.options()?.hideDelay ?? defaults.hideDelay,
|
|
139
|
+
showArrow: (this.showArrow() ?? this.options()?.showArrow ?? defaults.showArrow) !== false,
|
|
140
|
+
showOnHover: (this.showOnHover() ?? this.options()?.showOnHover ?? defaults.showOnHover) !== false,
|
|
141
|
+
showOnFocus: (this.showOnFocus() ?? this.options()?.showOnFocus ?? defaults.showOnFocus) !== false,
|
|
142
|
+
hideOnTooltipHover: (this.hideOnTooltipHover() ??
|
|
143
|
+
this.options()?.hideOnTooltipHover ??
|
|
144
|
+
defaults.hideOnTooltipHover) !== false,
|
|
145
|
+
hideOnClick: (this.hideOnClick() ?? this.options()?.hideOnClick ?? defaults.hideOnClick) !== false,
|
|
146
|
+
};
|
|
147
|
+
}, ...(ngDevMode ? [{ debugName: "effectiveOptions" }] : []));
|
|
148
|
+
tooltip = computed(() => this._tooltip()?.instance, ...(ngDevMode ? [{ debugName: "tooltip" }] : []));
|
|
149
|
+
constructor() {
|
|
150
|
+
super();
|
|
151
|
+
const abortSignal = abortSignalOnDestroy();
|
|
152
|
+
this.element.nativeElement.addEventListener('mouseenter', this.onMouseEnter.bind(this), {
|
|
153
|
+
signal: abortSignal,
|
|
154
|
+
});
|
|
155
|
+
this.element.nativeElement.addEventListener('mouseleave', this.onMouseLeave.bind(this), {
|
|
156
|
+
signal: abortSignal,
|
|
157
|
+
});
|
|
158
|
+
this.element.nativeElement.addEventListener('focus', this.onFocus.bind(this), {
|
|
159
|
+
signal: abortSignal,
|
|
160
|
+
});
|
|
161
|
+
this.element.nativeElement.addEventListener('blur', this.onBlur.bind(this), {
|
|
162
|
+
signal: abortSignal,
|
|
163
|
+
});
|
|
164
|
+
effect(() => {
|
|
165
|
+
const tooltip = this._tooltip();
|
|
166
|
+
if (tooltip)
|
|
167
|
+
this.updateContent(tooltip);
|
|
168
|
+
});
|
|
169
|
+
effect(() => this._tooltip()?.setInput('styleClass', this.styleClass()));
|
|
170
|
+
effect(() => this._tooltip()?.setInput('showOnlyIfTruncated', this.showOnlyIfTruncated()));
|
|
171
|
+
effect(() => this._tooltip()?.setInput('size', this.size()));
|
|
172
|
+
effect(() => this._tooltip()?.setInput('options', this.effectiveOptions()));
|
|
173
|
+
}
|
|
174
|
+
ngOnDestroy() {
|
|
175
|
+
this._tooltip()?.destroy();
|
|
176
|
+
this._tooltip.set(null);
|
|
177
|
+
}
|
|
178
|
+
show() {
|
|
179
|
+
const tooltip = this._tooltip();
|
|
180
|
+
if (tooltip) {
|
|
181
|
+
tooltip.instance.show();
|
|
182
|
+
}
|
|
183
|
+
else {
|
|
184
|
+
const tooltip = this.getTooltip();
|
|
185
|
+
if (tooltip) {
|
|
186
|
+
requestAnimationFrame(() => tooltip.show());
|
|
187
|
+
}
|
|
188
|
+
}
|
|
189
|
+
}
|
|
190
|
+
hide() {
|
|
191
|
+
this._tooltip()?.instance.hide();
|
|
192
|
+
}
|
|
193
|
+
onMouseEnter() {
|
|
194
|
+
if (this.effectiveOptions().showOnHover) {
|
|
195
|
+
this.show();
|
|
196
|
+
}
|
|
197
|
+
}
|
|
198
|
+
onMouseLeave() {
|
|
199
|
+
if (this.effectiveOptions().showOnHover) {
|
|
200
|
+
this.hide();
|
|
201
|
+
}
|
|
202
|
+
}
|
|
203
|
+
onFocus() {
|
|
204
|
+
if (this.effectiveOptions().showOnFocus) {
|
|
205
|
+
this.show();
|
|
206
|
+
}
|
|
207
|
+
}
|
|
208
|
+
onBlur() {
|
|
209
|
+
if (this.effectiveOptions().showOnFocus) {
|
|
210
|
+
this.hide();
|
|
211
|
+
}
|
|
212
|
+
}
|
|
213
|
+
getTooltip() {
|
|
214
|
+
let tooltip = this._tooltip();
|
|
215
|
+
if (!tooltip && this.content()) {
|
|
216
|
+
tooltip = this._viewContainerRef.createComponent(TooltipComponent);
|
|
217
|
+
tooltip.setInput('anchor', this.element.nativeElement);
|
|
218
|
+
this.updateContent(tooltip);
|
|
219
|
+
tooltip.setInput('styleClass', this.styleClass());
|
|
220
|
+
tooltip.setInput('showOnlyIfTruncated', this.showOnlyIfTruncated());
|
|
221
|
+
tooltip.setInput('size', this.size());
|
|
222
|
+
tooltip.setInput('options', this.effectiveOptions());
|
|
223
|
+
this._tooltip.set(tooltip);
|
|
224
|
+
}
|
|
225
|
+
return tooltip?.instance;
|
|
226
|
+
}
|
|
227
|
+
updateContent(tooltip) {
|
|
228
|
+
const content = this.content();
|
|
229
|
+
if (content instanceof TemplateRef) {
|
|
230
|
+
tooltip.setInput('text', null);
|
|
231
|
+
tooltip.setInput('content', content);
|
|
232
|
+
}
|
|
233
|
+
else {
|
|
234
|
+
tooltip.setInput('text', content);
|
|
235
|
+
tooltip.setInput('content', null);
|
|
236
|
+
}
|
|
237
|
+
}
|
|
238
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.1.0", ngImport: i0, type: NgnTooltip, deps: [], target: i0.ɵɵFactoryTarget.Directive });
|
|
239
|
+
static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "21.1.0", type: NgnTooltip, isStandalone: true, selector: "[ngnTooltip]", inputs: { content: { classPropertyName: "content", publicName: "ngnTooltip", isSignal: true, isRequired: false, transformFunction: null }, styleClass: { classPropertyName: "styleClass", publicName: "ngnTooltipStyleClass", isSignal: true, isRequired: false, transformFunction: null }, showOnlyIfTruncated: { classPropertyName: "showOnlyIfTruncated", publicName: "ngnTooltipShowOnlyIfTruncated", isSignal: true, isRequired: false, transformFunction: null }, size: { classPropertyName: "size", publicName: "ngnTooltipSize", isSignal: true, isRequired: false, transformFunction: null }, options: { classPropertyName: "options", publicName: "ngnTooltipOptions", isSignal: true, isRequired: false, transformFunction: null }, placement: { classPropertyName: "placement", publicName: "ngnTooltipPlacement", isSignal: true, isRequired: false, transformFunction: null }, offset: { classPropertyName: "offset", publicName: "ngnTooltipOffset", isSignal: true, isRequired: false, transformFunction: null }, showDelay: { classPropertyName: "showDelay", publicName: "ngnTooltipShowDelay", isSignal: true, isRequired: false, transformFunction: null }, hideDelay: { classPropertyName: "hideDelay", publicName: "ngnTooltipHideDelay", isSignal: true, isRequired: false, transformFunction: null }, showArrow: { classPropertyName: "showArrow", publicName: "ngnTooltipShowArrow", isSignal: true, isRequired: false, transformFunction: null }, showOnHover: { classPropertyName: "showOnHover", publicName: "ngnTooltipShowOnHover", isSignal: true, isRequired: false, transformFunction: null }, showOnFocus: { classPropertyName: "showOnFocus", publicName: "ngnTooltipShowOnFocus", isSignal: true, isRequired: false, transformFunction: null }, hideOnTooltipHover: { classPropertyName: "hideOnTooltipHover", publicName: "ngnTooltipHideOnTooltipHover", isSignal: true, isRequired: false, transformFunction: null }, hideOnClick: { classPropertyName: "hideOnClick", publicName: "ngnTooltipHideOnClick", isSignal: true, isRequired: false, transformFunction: null } }, providers: [provideSelf(NgnTooltip)], exportAs: ["ngnTooltip"], usesInheritance: true, ngImport: i0 });
|
|
240
|
+
}
|
|
241
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.1.0", ngImport: i0, type: NgnTooltip, decorators: [{
|
|
242
|
+
type: Directive,
|
|
243
|
+
args: [{
|
|
244
|
+
selector: '[ngnTooltip]',
|
|
245
|
+
exportAs: 'ngnTooltip',
|
|
246
|
+
providers: [provideSelf(NgnTooltip)],
|
|
247
|
+
}]
|
|
248
|
+
}], ctorParameters: () => [], propDecorators: { content: [{ type: i0.Input, args: [{ isSignal: true, alias: "ngnTooltip", required: false }] }], styleClass: [{ type: i0.Input, args: [{ isSignal: true, alias: "ngnTooltipStyleClass", required: false }] }], showOnlyIfTruncated: [{ type: i0.Input, args: [{ isSignal: true, alias: "ngnTooltipShowOnlyIfTruncated", required: false }] }], size: [{ type: i0.Input, args: [{ isSignal: true, alias: "ngnTooltipSize", required: false }] }], options: [{ type: i0.Input, args: [{ isSignal: true, alias: "ngnTooltipOptions", required: false }] }], placement: [{ type: i0.Input, args: [{ isSignal: true, alias: "ngnTooltipPlacement", required: false }] }], offset: [{ type: i0.Input, args: [{ isSignal: true, alias: "ngnTooltipOffset", required: false }] }], showDelay: [{ type: i0.Input, args: [{ isSignal: true, alias: "ngnTooltipShowDelay", required: false }] }], hideDelay: [{ type: i0.Input, args: [{ isSignal: true, alias: "ngnTooltipHideDelay", required: false }] }], showArrow: [{ type: i0.Input, args: [{ isSignal: true, alias: "ngnTooltipShowArrow", required: false }] }], showOnHover: [{ type: i0.Input, args: [{ isSignal: true, alias: "ngnTooltipShowOnHover", required: false }] }], showOnFocus: [{ type: i0.Input, args: [{ isSignal: true, alias: "ngnTooltipShowOnFocus", required: false }] }], hideOnTooltipHover: [{ type: i0.Input, args: [{ isSignal: true, alias: "ngnTooltipHideOnTooltipHover", required: false }] }], hideOnClick: [{ type: i0.Input, args: [{ isSignal: true, alias: "ngnTooltipHideOnClick", required: false }] }] } });
|
|
249
|
+
class TooltipComponent extends NgnBase {
|
|
250
|
+
_showHideTimeout;
|
|
251
|
+
theme = this.injectThemeTemplate(tooltipControlTemplate, {
|
|
252
|
+
root: true,
|
|
253
|
+
closing: () => this.isClosing(),
|
|
254
|
+
'with-arrow': () => this.options().showArrow !== false,
|
|
255
|
+
});
|
|
256
|
+
_config = inject(NGN_CONFIG);
|
|
257
|
+
/**
|
|
258
|
+
* The anchor element to which the tooltip is attached.
|
|
259
|
+
*/
|
|
260
|
+
anchor = input.required(...(ngDevMode ? [{ debugName: "anchor" }] : []));
|
|
261
|
+
/**
|
|
262
|
+
* The text content of the tooltip.
|
|
263
|
+
*/
|
|
264
|
+
text = input(...(ngDevMode ? [undefined, { debugName: "text" }] : []));
|
|
265
|
+
/**
|
|
266
|
+
* The content template of the tooltip.
|
|
267
|
+
*/
|
|
268
|
+
content = input(...(ngDevMode ? [undefined, { debugName: "content" }] : []));
|
|
269
|
+
/**
|
|
270
|
+
* If set to `true`, the tooltip will only be shown if the anchor element is truncated. `""` is equivalent to `true`.
|
|
271
|
+
* @default `false`
|
|
272
|
+
*/
|
|
273
|
+
showOnlyIfTruncated = input(false, ...(ngDevMode ? [{ debugName: "showOnlyIfTruncated" }] : []));
|
|
274
|
+
/**
|
|
275
|
+
* The size constraints for the tooltip.
|
|
276
|
+
* This can be used to limit the width and height of the tooltip.
|
|
277
|
+
* If not provided, the tooltip is only constrained by the size of the screen.
|
|
278
|
+
*/
|
|
279
|
+
size = input(...(ngDevMode ? [undefined, { debugName: "size" }] : []));
|
|
280
|
+
/**
|
|
281
|
+
* The options for the tooltip.
|
|
282
|
+
*
|
|
283
|
+
*/
|
|
284
|
+
options = input(this._config.defaults.tooltip, ...(ngDevMode ? [{ debugName: "options" }] : []));
|
|
285
|
+
showDelayMs = computed(() => getTimeSpanMilliseconds(this.options().showDelay), ...(ngDevMode ? [{ debugName: "showDelayMs" }] : []));
|
|
286
|
+
hideDelayMs = computed(() => getTimeSpanMilliseconds(this.options().hideDelay), ...(ngDevMode ? [{ debugName: "hideDelayMs" }] : []));
|
|
287
|
+
position = signal({ x: 0, y: 0 }, ...(ngDevMode ? [{ debugName: "position" }] : []));
|
|
288
|
+
positionClass = signal('', ...(ngDevMode ? [{ debugName: "positionClass" }] : []));
|
|
289
|
+
relativeAnchorElementPosition = signal(undefined, ...(ngDevMode ? [{ debugName: "relativeAnchorElementPosition" }] : []));
|
|
290
|
+
_isShown = signal(false, ...(ngDevMode ? [{ debugName: "_isShown" }] : []));
|
|
291
|
+
_isClosing = signal(false, ...(ngDevMode ? [{ debugName: "_isClosing" }] : []));
|
|
292
|
+
id = generateElementId();
|
|
293
|
+
isShown = this._isShown.asReadonly();
|
|
294
|
+
isClosing = this._isClosing.asReadonly();
|
|
295
|
+
_defaultContentTemplate = viewChild.required('defaultContentTemplate');
|
|
296
|
+
contentTemplate = computed(() => this.content() ?? this._defaultContentTemplate(), ...(ngDevMode ? [{ debugName: "contentTemplate" }] : []));
|
|
297
|
+
_autoPos = computedWithPrevious(prev => {
|
|
298
|
+
prev?.stop();
|
|
299
|
+
const element = this.element.nativeElement;
|
|
300
|
+
if (!element) {
|
|
301
|
+
return undefined;
|
|
302
|
+
}
|
|
303
|
+
return autoPositionElement(this.anchor(), element, {
|
|
304
|
+
injector: this.injector,
|
|
305
|
+
stopped: true,
|
|
306
|
+
resize: false,
|
|
307
|
+
sizeConstraints: this.size() ?? undefined,
|
|
308
|
+
placement: this.options().placement,
|
|
309
|
+
offset: this.options().offset,
|
|
310
|
+
middleware: [relativeAnchorElementPosition],
|
|
311
|
+
disableSettingStyles: true,
|
|
312
|
+
strategy: 'fixed',
|
|
313
|
+
onPositionChange: ({ x, y, placement, middlewareData }) => {
|
|
314
|
+
this.relativeAnchorElementPosition.set(middlewareData[relativeAnchorElementPosition.name]);
|
|
315
|
+
this.position.set({ x, y });
|
|
316
|
+
this.positionClass.set(splitPlacement(placement)
|
|
317
|
+
.filter(notNullish)
|
|
318
|
+
.map(x => this.theme.class(x))
|
|
319
|
+
.join(' '));
|
|
320
|
+
},
|
|
321
|
+
});
|
|
322
|
+
});
|
|
323
|
+
constructor() {
|
|
324
|
+
super();
|
|
325
|
+
const document = inject(DOCUMENT);
|
|
326
|
+
const destroyAbortSignal = abortSignalOnDestroy();
|
|
327
|
+
effect(() => {
|
|
328
|
+
if (this.isShown() && !this.isClosing()) {
|
|
329
|
+
document.addEventListener('keydown', this.onDocumentKeyDown.bind(this), {
|
|
330
|
+
signal: destroyAbortSignal,
|
|
331
|
+
});
|
|
332
|
+
}
|
|
333
|
+
else {
|
|
334
|
+
document.removeEventListener('keydown', this.onDocumentKeyDown.bind(this));
|
|
335
|
+
}
|
|
336
|
+
});
|
|
337
|
+
effect(() => {
|
|
338
|
+
if (this.isShown()) {
|
|
339
|
+
this._autoPos()?.start();
|
|
340
|
+
}
|
|
341
|
+
else {
|
|
342
|
+
this._autoPos()?.stop();
|
|
343
|
+
}
|
|
344
|
+
});
|
|
345
|
+
}
|
|
346
|
+
show(skipDelay = false) {
|
|
347
|
+
clearTimeout(this._showHideTimeout);
|
|
348
|
+
const delay = skipDelay ? 0 : this.showDelayMs();
|
|
349
|
+
if (delay <= 0) {
|
|
350
|
+
this.onShow();
|
|
351
|
+
}
|
|
352
|
+
else {
|
|
353
|
+
this._showHideTimeout = setTimeout(() => this.onShow(), delay);
|
|
354
|
+
}
|
|
355
|
+
}
|
|
356
|
+
hide(skipDelay = false) {
|
|
357
|
+
clearTimeout(this._showHideTimeout);
|
|
358
|
+
const delay = skipDelay ? 0 : this.hideDelayMs();
|
|
359
|
+
if (delay <= 0) {
|
|
360
|
+
this.onHide();
|
|
361
|
+
}
|
|
362
|
+
else {
|
|
363
|
+
this._showHideTimeout = setTimeout(() => this.onHide(), delay);
|
|
364
|
+
}
|
|
365
|
+
}
|
|
366
|
+
onMouseEnter() {
|
|
367
|
+
if (this.options().hideOnTooltipHover) {
|
|
368
|
+
this.hide(true);
|
|
369
|
+
}
|
|
370
|
+
else {
|
|
371
|
+
this.show(true);
|
|
372
|
+
}
|
|
373
|
+
}
|
|
374
|
+
onMouseLeave() {
|
|
375
|
+
this.hide();
|
|
376
|
+
}
|
|
377
|
+
onClick(event) {
|
|
378
|
+
if (this.options().hideOnClick) {
|
|
379
|
+
this.hide(true);
|
|
380
|
+
}
|
|
381
|
+
event.stopPropagation();
|
|
382
|
+
}
|
|
383
|
+
onDocumentKeyDown(event) {
|
|
384
|
+
if (event.key === 'Escape' || event.key === 'Esc') {
|
|
385
|
+
this.hide(true);
|
|
386
|
+
event.preventDefault();
|
|
387
|
+
}
|
|
388
|
+
}
|
|
389
|
+
onShow() {
|
|
390
|
+
if (!this.content() && !this.text()) {
|
|
391
|
+
return;
|
|
392
|
+
}
|
|
393
|
+
if (this.showOnlyIfTruncated() !== false && !isElementTruncated(this.anchor())) {
|
|
394
|
+
return;
|
|
395
|
+
}
|
|
396
|
+
this._isShown.set(true);
|
|
397
|
+
this.element.nativeElement.showPopover();
|
|
398
|
+
}
|
|
399
|
+
onHide() {
|
|
400
|
+
this._isClosing.set(true);
|
|
401
|
+
requestAnimationFrame(() => {
|
|
402
|
+
Promise.all(this.element.nativeElement.getAnimations().map(a => a.finished))
|
|
403
|
+
.then(() => this.element.nativeElement.hidePopover())
|
|
404
|
+
.catch(() => { })
|
|
405
|
+
.finally(() => this._isClosing.set(false));
|
|
406
|
+
});
|
|
407
|
+
}
|
|
408
|
+
onToggle(event) {
|
|
409
|
+
const evt = event;
|
|
410
|
+
if (evt.newState === 'closed') {
|
|
411
|
+
this._isShown.set(false);
|
|
412
|
+
}
|
|
413
|
+
else {
|
|
414
|
+
this._isShown.set(true);
|
|
415
|
+
}
|
|
416
|
+
}
|
|
417
|
+
toPixels(value) {
|
|
418
|
+
return value !== undefined ? `${value}px` : undefined;
|
|
419
|
+
}
|
|
420
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.1.0", ngImport: i0, type: TooltipComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
421
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.2.0", version: "21.1.0", type: TooltipComponent, isStandalone: true, selector: "ngn-tooltip", inputs: { anchor: { classPropertyName: "anchor", publicName: "anchor", isSignal: true, isRequired: true, transformFunction: null }, text: { classPropertyName: "text", publicName: "text", isSignal: true, isRequired: false, transformFunction: null }, content: { classPropertyName: "content", publicName: "content", isSignal: true, isRequired: false, transformFunction: null }, showOnlyIfTruncated: { classPropertyName: "showOnlyIfTruncated", publicName: "showOnlyIfTruncated", isSignal: true, isRequired: false, transformFunction: null }, size: { classPropertyName: "size", publicName: "size", isSignal: true, isRequired: false, transformFunction: null }, options: { classPropertyName: "options", publicName: "options", isSignal: true, isRequired: false, transformFunction: null } }, host: { listeners: { "toggle": "onToggle($event)", "mouseenter": "onMouseEnter()", "mouseleave": "onMouseLeave()", "click": "onClick($event)" }, properties: { "class": "positionClass()", "style.--anchor-start": "toPixels(relativeAnchorElementPosition()?.start)", "style.--anchor-center": "toPixels(relativeAnchorElementPosition()?.center)", "style.--anchor-end": "toPixels(relativeAnchorElementPosition()?.end)", "style.left": "toPixels(position().x)", "style.top": "toPixels(position().y)", "attr.popover": "'hint'", "attr.id": "id", "attr.role": "'tooltip'" } }, providers: [provideSelf(TooltipComponent)], viewQueries: [{ propertyName: "_defaultContentTemplate", first: true, predicate: ["defaultContentTemplate"], descendants: true, isSignal: true }], usesInheritance: true, ngImport: i0, template: "<div [ptInt]=\"this\" [ptClass]=\"'content'\">\r\n <ngn-defer [lazyContent]=\"contentTemplate()\" [open]=\"isShown()\" [cache]=\"false\"></ngn-defer>\r\n</div>\r\n\r\n<ng-template #defaultContentTemplate>\r\n <span [ptInt]=\"this\" [ptClass]=\"'text'\">{{ text() }}</span>\r\n</ng-template>\r\n", dependencies: [{ kind: "directive", type: NgnPt, selector: "[ptInt]", inputs: ["ptInt", "ptClass"] }, { kind: "component", type: NgnDefer, selector: "ngn-defer", inputs: ["lazyContent", "lazyContentContext", "open", "lazy", "cache", "hiddenOnClosed"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
422
|
+
}
|
|
423
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.1.0", ngImport: i0, type: TooltipComponent, decorators: [{
|
|
424
|
+
type: Component,
|
|
425
|
+
args: [{ changeDetection: ChangeDetectionStrategy.OnPush, selector: 'ngn-tooltip', imports: [NgnPt, NgnDefer], providers: [provideSelf(TooltipComponent)], host: {
|
|
426
|
+
'[class]': `positionClass()`,
|
|
427
|
+
'[style.--anchor-start]': `toPixels(relativeAnchorElementPosition()?.start)`,
|
|
428
|
+
'[style.--anchor-center]': `toPixels(relativeAnchorElementPosition()?.center)`,
|
|
429
|
+
'[style.--anchor-end]': `toPixels(relativeAnchorElementPosition()?.end)`,
|
|
430
|
+
'[style.left]': `toPixels(position().x)`,
|
|
431
|
+
'[style.top]': `toPixels(position().y)`,
|
|
432
|
+
'[attr.popover]': `'hint'`,
|
|
433
|
+
'[attr.id]': `id`,
|
|
434
|
+
'[attr.role]': `'tooltip'`,
|
|
435
|
+
'(toggle)': 'onToggle($event)',
|
|
436
|
+
'(mouseenter)': 'onMouseEnter()',
|
|
437
|
+
'(mouseleave)': 'onMouseLeave()',
|
|
438
|
+
'(click)': 'onClick($event)',
|
|
439
|
+
}, template: "<div [ptInt]=\"this\" [ptClass]=\"'content'\">\r\n <ngn-defer [lazyContent]=\"contentTemplate()\" [open]=\"isShown()\" [cache]=\"false\"></ngn-defer>\r\n</div>\r\n\r\n<ng-template #defaultContentTemplate>\r\n <span [ptInt]=\"this\" [ptClass]=\"'text'\">{{ text() }}</span>\r\n</ng-template>\r\n" }]
|
|
440
|
+
}], ctorParameters: () => [], propDecorators: { anchor: [{ type: i0.Input, args: [{ isSignal: true, alias: "anchor", required: true }] }], text: [{ type: i0.Input, args: [{ isSignal: true, alias: "text", required: false }] }], content: [{ type: i0.Input, args: [{ isSignal: true, alias: "content", required: false }] }], showOnlyIfTruncated: [{ type: i0.Input, args: [{ isSignal: true, alias: "showOnlyIfTruncated", required: false }] }], size: [{ type: i0.Input, args: [{ isSignal: true, alias: "size", required: false }] }], options: [{ type: i0.Input, args: [{ isSignal: true, alias: "options", required: false }] }], _defaultContentTemplate: [{ type: i0.ViewChild, args: ['defaultContentTemplate', { isSignal: true }] }] } });
|
|
441
|
+
function isElementTruncated(element) {
|
|
442
|
+
return (element.clientWidth < element.scrollWidth || // horizontal overflow
|
|
443
|
+
element.clientHeight < element.scrollHeight || // vertical overflow
|
|
444
|
+
element.offsetWidth < element.scrollWidth || // single-line ellipsis
|
|
445
|
+
element.offsetHeight < element.scrollHeight // multi-line ellipsis (line-clamp)
|
|
446
|
+
);
|
|
447
|
+
}
|
|
448
|
+
|
|
449
|
+
/**
|
|
450
|
+
* Generated bundle index. Do not edit.
|
|
451
|
+
*/
|
|
452
|
+
|
|
453
|
+
export { NgnTooltip, TooltipComponent };
|
|
454
|
+
//# sourceMappingURL=ngneers-controls-tooltip.mjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ngneers-controls-tooltip.mjs","sources":["../../src/tooltip/relative-anchor-element-position.ts","../../src/tooltip/tooltip.ts","../../src/tooltip/tooltip.html","../../src/tooltip/ngneers-controls-tooltip.ts"],"sourcesContent":["import type { Middleware, Placement } from '@floating-ui/dom';\r\n\r\nexport type RelativeAnchorElementPositionData = {\r\n start: number;\r\n center: number;\r\n end: number;\r\n};\r\n\r\nexport const relativeAnchorElementPosition: Middleware = {\r\n name: 'relativeAnchorElementPosition',\r\n async fn(state) {\r\n const { placement, rects } = state;\r\n\r\n const axis = getAxis(placement);\r\n const axisSize = axis === 'x' ? 'width' : 'height';\r\n\r\n return {\r\n data: {\r\n start: rects.reference[axis] - state[axis],\r\n center: rects.reference[axis] + rects.reference[axisSize] / 2 - state[axis],\r\n end: rects.reference[axis] + rects.reference[axisSize] - state[axis],\r\n } satisfies RelativeAnchorElementPositionData,\r\n };\r\n },\r\n};\r\n\r\nfunction getAxis(placement: Placement): 'x' | 'y' {\r\n switch (placement.split('-')[0]) {\r\n case 'top':\r\n case 'bottom':\r\n return 'x';\r\n case 'left':\r\n case 'right':\r\n return 'y';\r\n default:\r\n throw new Error(`Unknown placement: ${placement}`);\r\n }\r\n}\r\n","import {\r\n Component,\r\n ComponentRef,\r\n computed,\r\n Directive,\r\n DOCUMENT,\r\n effect,\r\n inject,\r\n input,\r\n type OnDestroy,\r\n signal,\r\n TemplateRef,\r\n viewChild,\r\n ViewContainerRef,\r\n ChangeDetectionStrategy,\r\n} from '@angular/core';\r\nimport {\r\n abortSignalOnDestroy,\r\n autoPositionElement,\r\n type AutoPositioningHandle,\r\n NGN_CONFIG,\r\n type PositioningSizeConstraints,\r\n splitPlacement,\r\n type TooltipOptions,\r\n} from '@ngneers/controls/api/ng';\r\nimport { NgnBase, provideSelf, NgnPt } from '@ngneers/controls/base';\r\nimport { NgnDefer } from '@ngneers/controls/defer';\r\nimport { getTimeSpanMilliseconds, notNullish, type TimeSpan } from '@ngneers/controls/utils';\r\nimport { computedWithPrevious, generateElementId } from '@ngneers/controls/utils-ng';\r\nimport { tooltipControlTemplate } from '@ngneers/controls-themes/templates/tooltip';\r\n\r\nimport {\r\n relativeAnchorElementPosition,\r\n type RelativeAnchorElementPositionData,\r\n} from './relative-anchor-element-position';\r\n\r\nimport type { Placement } from '@floating-ui/dom';\r\n\r\n/**\r\n * @category control\r\n */\r\n@Directive({\r\n selector: '[ngnTooltip]',\r\n exportAs: 'ngnTooltip',\r\n providers: [provideSelf(NgnTooltip)],\r\n})\r\nexport class NgnTooltip extends NgnBase<'tooltip'> implements OnDestroy {\r\n protected readonly theme = null;\r\n private readonly _viewContainerRef = inject(ViewContainerRef);\r\n private readonly _config = inject(NGN_CONFIG);\r\n private readonly _tooltip = signal<ComponentRef<TooltipComponent> | null>(null);\r\n\r\n /**\r\n * The content of the tooltip, can be a string or a TemplateRef.\r\n * If the value is falsy, the tooltip will not be shown.\r\n * @alias ngnTooltip\r\n */\r\n public readonly content = input<TemplateRef<unknown> | string | null | undefined>(null, {\r\n alias: 'ngnTooltip',\r\n });\r\n /**\r\n * The CSS class to apply to the tooltip.\r\n * This can be used to apply custom styles to the tooltip.\r\n * @alias ngnTooltipStyleClass\r\n */\r\n public readonly styleClass = input<string | null | undefined>(null, {\r\n alias: 'ngnTooltipStyleClass',\r\n });\r\n /**\r\n * If set to `true`, the tooltip will only be shown if the anchor element is truncated. `\"\"` is equivalent to `true`.\r\n * @alias ngnTooltipShowOnlyIfTruncated\r\n * @default false\r\n */\r\n public readonly showOnlyIfTruncated = input<boolean | ''>(false, {\r\n alias: 'ngnTooltipShowOnlyIfTruncated',\r\n });\r\n /**\r\n * The size constraints for the tooltip.\r\n * This can be used to limit the width and height of the tooltip.\r\n * If not provided, the tooltip is only constrained by the size of the screen.\r\n * @alias ngnTooltipSize\r\n */\r\n public readonly size = input<PositioningSizeConstraints | null | undefined>(null, {\r\n alias: 'ngnTooltipSize',\r\n });\r\n\r\n /**\r\n * The options for the tooltip.\r\n * This is a shorthand for setting multiple options at once.\r\n * The individual options take precedence over the options set here.\r\n * @alias ngnTooltipOptions\r\n */\r\n public readonly options = input<Partial<TooltipOptions> | null | undefined>(null, {\r\n alias: 'ngnTooltipOptions',\r\n });\r\n /**\r\n * The placement of the tooltip relative to the anchor element.\r\n * @alias ngnTooltipPlacement\r\n * @default 'bottom'\r\n */\r\n public readonly placement = input<Placement | null | undefined>(null, {\r\n alias: 'ngnTooltipPlacement',\r\n });\r\n /**\r\n * The offset in Pixels of the tooltip from the anchor element.\r\n * @alias ngnTooltipOffset\r\n * @default 4\r\n */\r\n public readonly offset = input<number | null | undefined>(null, {\r\n alias: 'ngnTooltipOffset',\r\n });\r\n /**\r\n * The delay before the tooltip is shown. If a number is provided, it is interpreted as milliseconds.\r\n * @alias ngnTooltipShowDelay\r\n * @default '0.5s'\r\n */\r\n public readonly showDelay = input<TimeSpan | null | undefined>(null, {\r\n alias: 'ngnTooltipShowDelay',\r\n });\r\n /**\r\n * The delay before the tooltip is hidden. If a number is provided, it is interpreted as milliseconds.\r\n * @alias ngnTooltipHideDelay\r\n * @default '0.1s'\r\n */\r\n public readonly hideDelay = input<TimeSpan | null | undefined>(null, {\r\n alias: 'ngnTooltipHideDelay',\r\n });\r\n /**\r\n * Whether to show an arrow pointing to the anchor element. `\"\"` is equivalent to `true`.\r\n * @alias ngnTooltipShowArrow\r\n * @default true\r\n */\r\n public readonly showArrow = input<boolean | '' | null | undefined>(null, {\r\n alias: 'ngnTooltipShowArrow',\r\n });\r\n /**\r\n * Shows the tooltip on hover.\r\n * @alias ngnTooltipShowOnHover\r\n * @default true\r\n */\r\n public readonly showOnHover = input<boolean | '' | null | undefined>(null, {\r\n alias: 'ngnTooltipShowOnHover',\r\n });\r\n /**\r\n * Shows the tooltip on focus.\r\n * @alias ngnTooltipShowOnFocus\r\n * @default true\r\n */\r\n public readonly showOnFocus = input<boolean | '' | null | undefined>(null, {\r\n alias: 'ngnTooltipShowOnFocus',\r\n });\r\n /**\r\n * Hides the tooltip (without delay) when the mouse hovers over the tooltip.\r\n * @alias ngnTooltipHideOnTooltipHover\r\n * @default false\r\n */\r\n public readonly hideOnTooltipHover = input<boolean | '' | null | undefined>(null, {\r\n alias: 'ngnTooltipHideOnTooltipHover',\r\n });\r\n /**\r\n * Hides the tooltip (without delay) when the user clicks on the tooltip.\r\n * @alias ngnTooltipHideOnClick\r\n * @default true\r\n */\r\n public readonly hideOnClick = input<boolean | '' | null | undefined>(null, {\r\n alias: 'ngnTooltipHideOnClick',\r\n });\r\n\r\n public readonly effectiveOptions = computed<TooltipOptions>(() => {\r\n const defaults = this._config.defaults.tooltip;\r\n return {\r\n placement: this.placement() ?? this.options()?.placement ?? defaults.placement,\r\n offset: this.offset() ?? this.options()?.offset ?? defaults.offset,\r\n showDelay: this.showDelay() ?? this.options()?.showDelay ?? defaults.showDelay,\r\n hideDelay: this.hideDelay() ?? this.options()?.hideDelay ?? defaults.hideDelay,\r\n showArrow: (this.showArrow() ?? this.options()?.showArrow ?? defaults.showArrow) !== false,\r\n showOnHover:\r\n (this.showOnHover() ?? this.options()?.showOnHover ?? defaults.showOnHover) !== false,\r\n showOnFocus:\r\n (this.showOnFocus() ?? this.options()?.showOnFocus ?? defaults.showOnFocus) !== false,\r\n hideOnTooltipHover:\r\n (this.hideOnTooltipHover() ??\r\n this.options()?.hideOnTooltipHover ??\r\n defaults.hideOnTooltipHover) !== false,\r\n hideOnClick:\r\n (this.hideOnClick() ?? this.options()?.hideOnClick ?? defaults.hideOnClick) !== false,\r\n };\r\n });\r\n\r\n public readonly tooltip = computed(() => this._tooltip()?.instance);\r\n\r\n constructor() {\r\n super();\r\n\r\n const abortSignal = abortSignalOnDestroy();\r\n this.element.nativeElement.addEventListener('mouseenter', this.onMouseEnter.bind(this), {\r\n signal: abortSignal,\r\n });\r\n this.element.nativeElement.addEventListener('mouseleave', this.onMouseLeave.bind(this), {\r\n signal: abortSignal,\r\n });\r\n this.element.nativeElement.addEventListener('focus', this.onFocus.bind(this), {\r\n signal: abortSignal,\r\n });\r\n this.element.nativeElement.addEventListener('blur', this.onBlur.bind(this), {\r\n signal: abortSignal,\r\n });\r\n\r\n effect(() => {\r\n const tooltip = this._tooltip();\r\n if (tooltip) this.updateContent(tooltip);\r\n });\r\n effect(() => this._tooltip()?.setInput('styleClass', this.styleClass()));\r\n effect(() => this._tooltip()?.setInput('showOnlyIfTruncated', this.showOnlyIfTruncated()));\r\n effect(() => this._tooltip()?.setInput('size', this.size()));\r\n effect(() => this._tooltip()?.setInput('options', this.effectiveOptions()));\r\n }\r\n\r\n public ngOnDestroy(): void {\r\n this._tooltip()?.destroy();\r\n this._tooltip.set(null);\r\n }\r\n\r\n public show(): void {\r\n const tooltip = this._tooltip();\r\n if (tooltip) {\r\n tooltip.instance.show();\r\n } else {\r\n const tooltip = this.getTooltip();\r\n if (tooltip) {\r\n requestAnimationFrame(() => tooltip.show());\r\n }\r\n }\r\n }\r\n\r\n public hide(): void {\r\n this._tooltip()?.instance.hide();\r\n }\r\n\r\n protected onMouseEnter() {\r\n if (this.effectiveOptions().showOnHover) {\r\n this.show();\r\n }\r\n }\r\n\r\n protected onMouseLeave() {\r\n if (this.effectiveOptions().showOnHover) {\r\n this.hide();\r\n }\r\n }\r\n\r\n protected onFocus() {\r\n if (this.effectiveOptions().showOnFocus) {\r\n this.show();\r\n }\r\n }\r\n\r\n protected onBlur() {\r\n if (this.effectiveOptions().showOnFocus) {\r\n this.hide();\r\n }\r\n }\r\n\r\n private getTooltip(): TooltipComponent | undefined {\r\n let tooltip = this._tooltip();\r\n if (!tooltip && this.content()) {\r\n tooltip = this._viewContainerRef.createComponent(TooltipComponent);\r\n tooltip.setInput('anchor', this.element.nativeElement);\r\n this.updateContent(tooltip);\r\n tooltip.setInput('styleClass', this.styleClass());\r\n tooltip.setInput('showOnlyIfTruncated', this.showOnlyIfTruncated());\r\n tooltip.setInput('size', this.size());\r\n tooltip.setInput('options', this.effectiveOptions());\r\n this._tooltip.set(tooltip);\r\n }\r\n return tooltip?.instance;\r\n }\r\n\r\n private updateContent(tooltip: ComponentRef<TooltipComponent>) {\r\n const content = this.content();\r\n if (content instanceof TemplateRef) {\r\n tooltip.setInput('text', null);\r\n tooltip.setInput('content', content);\r\n } else {\r\n tooltip.setInput('text', content);\r\n tooltip.setInput('content', null);\r\n }\r\n }\r\n}\r\n\r\n@Component({\r\n changeDetection: ChangeDetectionStrategy.OnPush,\r\n selector: 'ngn-tooltip',\r\n templateUrl: './tooltip.html',\r\n imports: [NgnPt, NgnDefer],\r\n providers: [provideSelf(TooltipComponent)],\r\n host: {\r\n '[class]': `positionClass()`,\r\n '[style.--anchor-start]': `toPixels(relativeAnchorElementPosition()?.start)`,\r\n '[style.--anchor-center]': `toPixels(relativeAnchorElementPosition()?.center)`,\r\n '[style.--anchor-end]': `toPixels(relativeAnchorElementPosition()?.end)`,\r\n '[style.left]': `toPixels(position().x)`,\r\n '[style.top]': `toPixels(position().y)`,\r\n '[attr.popover]': `'hint'`,\r\n '[attr.id]': `id`,\r\n '[attr.role]': `'tooltip'`,\r\n '(toggle)': 'onToggle($event)',\r\n '(mouseenter)': 'onMouseEnter()',\r\n '(mouseleave)': 'onMouseLeave()',\r\n '(click)': 'onClick($event)',\r\n },\r\n})\r\nexport class TooltipComponent extends NgnBase<'tooltip'> {\r\n private _showHideTimeout?: ReturnType<typeof setTimeout>;\r\n protected readonly theme = this.injectThemeTemplate(tooltipControlTemplate, {\r\n root: true,\r\n closing: () => this.isClosing(),\r\n 'with-arrow': () => this.options().showArrow !== false,\r\n });\r\n private readonly _config = inject(NGN_CONFIG);\r\n\r\n /**\r\n * The anchor element to which the tooltip is attached.\r\n */\r\n public readonly anchor = input.required<HTMLElement>();\r\n /**\r\n * The text content of the tooltip.\r\n */\r\n public readonly text = input<string | null>();\r\n /**\r\n * The content template of the tooltip.\r\n */\r\n public readonly content = input<TemplateRef<unknown>>();\r\n /**\r\n * If set to `true`, the tooltip will only be shown if the anchor element is truncated. `\"\"` is equivalent to `true`.\r\n * @default `false`\r\n */\r\n public readonly showOnlyIfTruncated = input<boolean | ''>(false);\r\n /**\r\n * The size constraints for the tooltip.\r\n * This can be used to limit the width and height of the tooltip.\r\n * If not provided, the tooltip is only constrained by the size of the screen.\r\n */\r\n public readonly size = input<PositioningSizeConstraints | null>();\r\n /**\r\n * The options for the tooltip.\r\n *\r\n */\r\n public readonly options = input<TooltipOptions>(this._config.defaults.tooltip);\r\n\r\n protected readonly showDelayMs = computed(() =>\r\n getTimeSpanMilliseconds(this.options().showDelay)\r\n );\r\n protected readonly hideDelayMs = computed(() =>\r\n getTimeSpanMilliseconds(this.options().hideDelay)\r\n );\r\n\r\n protected readonly position = signal<{ x: number; y: number }>({ x: 0, y: 0 });\r\n protected readonly positionClass = signal<string>('');\r\n protected readonly relativeAnchorElementPosition = signal<\r\n RelativeAnchorElementPositionData | undefined\r\n >(undefined);\r\n\r\n private readonly _isShown = signal(false);\r\n private readonly _isClosing = signal(false);\r\n\r\n public readonly id = generateElementId();\r\n public readonly isShown = this._isShown.asReadonly();\r\n public readonly isClosing = this._isClosing.asReadonly();\r\n\r\n private readonly _defaultContentTemplate =\r\n viewChild.required<TemplateRef<unknown>>('defaultContentTemplate');\r\n protected readonly contentTemplate = computed(\r\n () => this.content() ?? this._defaultContentTemplate()\r\n );\r\n\r\n private readonly _autoPos = computedWithPrevious<AutoPositioningHandle | undefined>(prev => {\r\n prev?.stop();\r\n const element = this.element.nativeElement;\r\n if (!element) {\r\n return undefined;\r\n }\r\n return autoPositionElement(this.anchor(), element, {\r\n injector: this.injector,\r\n stopped: true,\r\n resize: false,\r\n sizeConstraints: this.size() ?? undefined,\r\n placement: this.options().placement,\r\n offset: this.options().offset,\r\n middleware: [relativeAnchorElementPosition],\r\n disableSettingStyles: true,\r\n strategy: 'fixed',\r\n onPositionChange: ({ x, y, placement, middlewareData }) => {\r\n this.relativeAnchorElementPosition.set(middlewareData[relativeAnchorElementPosition.name]);\r\n this.position.set({ x, y });\r\n this.positionClass.set(\r\n splitPlacement(placement)\r\n .filter(notNullish)\r\n .map(x => this.theme.class(x))\r\n .join(' ')\r\n );\r\n },\r\n });\r\n });\r\n\r\n constructor() {\r\n super();\r\n const document = inject(DOCUMENT);\r\n const destroyAbortSignal = abortSignalOnDestroy();\r\n effect(() => {\r\n if (this.isShown() && !this.isClosing()) {\r\n document.addEventListener('keydown', this.onDocumentKeyDown.bind(this), {\r\n signal: destroyAbortSignal,\r\n });\r\n } else {\r\n document.removeEventListener('keydown', this.onDocumentKeyDown.bind(this));\r\n }\r\n });\r\n effect(() => {\r\n if (this.isShown()) {\r\n this._autoPos()?.start();\r\n } else {\r\n this._autoPos()?.stop();\r\n }\r\n });\r\n }\r\n\r\n public show(skipDelay = false) {\r\n clearTimeout(this._showHideTimeout);\r\n\r\n const delay = skipDelay ? 0 : this.showDelayMs();\r\n if (delay <= 0) {\r\n this.onShow();\r\n } else {\r\n this._showHideTimeout = setTimeout(() => this.onShow(), delay);\r\n }\r\n }\r\n\r\n public hide(skipDelay = false) {\r\n clearTimeout(this._showHideTimeout);\r\n\r\n const delay = skipDelay ? 0 : this.hideDelayMs();\r\n if (delay <= 0) {\r\n this.onHide();\r\n } else {\r\n this._showHideTimeout = setTimeout(() => this.onHide(), delay);\r\n }\r\n }\r\n\r\n protected onMouseEnter() {\r\n if (this.options().hideOnTooltipHover) {\r\n this.hide(true);\r\n } else {\r\n this.show(true);\r\n }\r\n }\r\n\r\n protected onMouseLeave() {\r\n this.hide();\r\n }\r\n\r\n protected onClick(event: PointerEvent) {\r\n if (this.options().hideOnClick) {\r\n this.hide(true);\r\n }\r\n event.stopPropagation();\r\n }\r\n\r\n protected onDocumentKeyDown(event: KeyboardEvent) {\r\n if (event.key === 'Escape' || event.key === 'Esc') {\r\n this.hide(true);\r\n event.preventDefault();\r\n }\r\n }\r\n\r\n protected onShow() {\r\n if (!this.content() && !this.text()) {\r\n return;\r\n }\r\n if (this.showOnlyIfTruncated() !== false && !isElementTruncated(this.anchor())) {\r\n return;\r\n }\r\n\r\n this._isShown.set(true);\r\n this.element.nativeElement.showPopover();\r\n }\r\n\r\n protected onHide() {\r\n this._isClosing.set(true);\r\n requestAnimationFrame(() => {\r\n Promise.all(this.element.nativeElement.getAnimations().map(a => a.finished))\r\n .then(() => this.element.nativeElement.hidePopover())\r\n .catch(() => {})\r\n .finally(() => this._isClosing.set(false));\r\n });\r\n }\r\n\r\n protected onToggle(event: Event) {\r\n const evt = event as ToggleEvent;\r\n if (evt.newState === 'closed') {\r\n this._isShown.set(false);\r\n } else {\r\n this._isShown.set(true);\r\n }\r\n }\r\n\r\n protected toPixels(value: number | undefined): string | undefined {\r\n return value !== undefined ? `${value}px` : undefined;\r\n }\r\n}\r\n\r\nfunction isElementTruncated(element: HTMLElement): boolean {\r\n return (\r\n element.clientWidth < element.scrollWidth || // horizontal overflow\r\n element.clientHeight < element.scrollHeight || // vertical overflow\r\n element.offsetWidth < element.scrollWidth || // single-line ellipsis\r\n element.offsetHeight < element.scrollHeight // multi-line ellipsis (line-clamp)\r\n );\r\n}\r\n","<div [ptInt]=\"this\" [ptClass]=\"'content'\">\r\n <ngn-defer [lazyContent]=\"contentTemplate()\" [open]=\"isShown()\" [cache]=\"false\"></ngn-defer>\r\n</div>\r\n\r\n<ng-template #defaultContentTemplate>\r\n <span [ptInt]=\"this\" [ptClass]=\"'text'\">{{ text() }}</span>\r\n</ng-template>\r\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;;;;;AAQO,MAAM,6BAA6B,GAAe;AACvD,IAAA,IAAI,EAAE,+BAA+B;IACrC,MAAM,EAAE,CAAC,KAAK,EAAA;AACZ,QAAA,MAAM,EAAE,SAAS,EAAE,KAAK,EAAE,GAAG,KAAK;AAElC,QAAA,MAAM,IAAI,GAAG,OAAO,CAAC,SAAS,CAAC;AAC/B,QAAA,MAAM,QAAQ,GAAG,IAAI,KAAK,GAAG,GAAG,OAAO,GAAG,QAAQ;QAElD,OAAO;AACL,YAAA,IAAI,EAAE;gBACJ,KAAK,EAAE,KAAK,CAAC,SAAS,CAAC,IAAI,CAAC,GAAG,KAAK,CAAC,IAAI,CAAC;gBAC1C,MAAM,EAAE,KAAK,CAAC,SAAS,CAAC,IAAI,CAAC,GAAG,KAAK,CAAC,SAAS,CAAC,QAAQ,CAAC,GAAG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