@qualcomm-ui/angular-core 1.6.0 → 2.0.0
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/fesm2022/qualcomm-ui-angular-core-accordion.mjs +44 -50
- package/fesm2022/qualcomm-ui-angular-core-accordion.mjs.map +1 -1
- package/fesm2022/qualcomm-ui-angular-core-avatar.mjs +24 -24
- package/fesm2022/qualcomm-ui-angular-core-avatar.mjs.map +1 -1
- package/fesm2022/qualcomm-ui-angular-core-checkbox.mjs +56 -66
- package/fesm2022/qualcomm-ui-angular-core-checkbox.mjs.map +1 -1
- package/fesm2022/qualcomm-ui-angular-core-collapsible.mjs +22 -24
- package/fesm2022/qualcomm-ui-angular-core-collapsible.mjs.map +1 -1
- package/fesm2022/qualcomm-ui-angular-core-collection.mjs +3 -3
- package/fesm2022/qualcomm-ui-angular-core-collection.mjs.map +1 -1
- package/fesm2022/qualcomm-ui-angular-core-combobox.mjs +116 -152
- package/fesm2022/qualcomm-ui-angular-core-combobox.mjs.map +1 -1
- package/fesm2022/qualcomm-ui-angular-core-dialog.mjs +64 -78
- package/fesm2022/qualcomm-ui-angular-core-dialog.mjs.map +1 -1
- package/fesm2022/qualcomm-ui-angular-core-dom.mjs +15 -15
- package/fesm2022/qualcomm-ui-angular-core-dom.mjs.map +1 -1
- package/fesm2022/qualcomm-ui-angular-core-events.mjs +4 -4
- package/fesm2022/qualcomm-ui-angular-core-events.mjs.map +1 -1
- package/fesm2022/qualcomm-ui-angular-core-highlight.mjs +9 -15
- package/fesm2022/qualcomm-ui-angular-core-highlight.mjs.map +1 -1
- package/fesm2022/qualcomm-ui-angular-core-inline-notification.mjs +32 -32
- package/fesm2022/qualcomm-ui-angular-core-inline-notification.mjs.map +1 -1
- package/fesm2022/qualcomm-ui-angular-core-input.mjs +35 -51
- package/fesm2022/qualcomm-ui-angular-core-input.mjs.map +1 -1
- package/fesm2022/qualcomm-ui-angular-core-locale.mjs +3 -3
- package/fesm2022/qualcomm-ui-angular-core-locale.mjs.map +1 -1
- package/fesm2022/qualcomm-ui-angular-core-lorem-ipsum.mjs +11 -23
- package/fesm2022/qualcomm-ui-angular-core-lorem-ipsum.mjs.map +1 -1
- package/fesm2022/qualcomm-ui-angular-core-machine.mjs +20 -20
- package/fesm2022/qualcomm-ui-angular-core-machine.mjs.map +1 -1
- package/fesm2022/qualcomm-ui-angular-core-menu.mjs +111 -127
- package/fesm2022/qualcomm-ui-angular-core-menu.mjs.map +1 -1
- package/fesm2022/qualcomm-ui-angular-core-number-input.mjs +80 -106
- package/fesm2022/qualcomm-ui-angular-core-number-input.mjs.map +1 -1
- package/fesm2022/qualcomm-ui-angular-core-observers.mjs +3 -3
- package/fesm2022/qualcomm-ui-angular-core-observers.mjs.map +1 -1
- package/fesm2022/qualcomm-ui-angular-core-pagination.mjs +46 -60
- package/fesm2022/qualcomm-ui-angular-core-pagination.mjs.map +1 -1
- package/fesm2022/qualcomm-ui-angular-core-password-input.mjs +46 -50
- package/fesm2022/qualcomm-ui-angular-core-password-input.mjs.map +1 -1
- package/fesm2022/qualcomm-ui-angular-core-popover.mjs +62 -66
- package/fesm2022/qualcomm-ui-angular-core-popover.mjs.map +1 -1
- package/fesm2022/qualcomm-ui-angular-core-portal.mjs +18 -22
- package/fesm2022/qualcomm-ui-angular-core-portal.mjs.map +1 -1
- package/fesm2022/qualcomm-ui-angular-core-presence.mjs +18 -24
- package/fesm2022/qualcomm-ui-angular-core-presence.mjs.map +1 -1
- package/fesm2022/qualcomm-ui-angular-core-progress-ring.mjs +30 -30
- package/fesm2022/qualcomm-ui-angular-core-progress-ring.mjs.map +1 -1
- package/fesm2022/qualcomm-ui-angular-core-progress.mjs +42 -54
- package/fesm2022/qualcomm-ui-angular-core-progress.mjs.map +1 -1
- package/fesm2022/qualcomm-ui-angular-core-radio.mjs +72 -80
- package/fesm2022/qualcomm-ui-angular-core-radio.mjs.map +1 -1
- package/fesm2022/qualcomm-ui-angular-core-segmented-control.mjs +32 -38
- package/fesm2022/qualcomm-ui-angular-core-segmented-control.mjs.map +1 -1
- package/fesm2022/qualcomm-ui-angular-core-select.mjs +88 -102
- package/fesm2022/qualcomm-ui-angular-core-select.mjs.map +1 -1
- package/fesm2022/qualcomm-ui-angular-core-side-nav.mjs +44 -58
- package/fesm2022/qualcomm-ui-angular-core-side-nav.mjs.map +1 -1
- package/fesm2022/qualcomm-ui-angular-core-signals.mjs +2 -2
- package/fesm2022/qualcomm-ui-angular-core-signals.mjs.map +1 -1
- package/fesm2022/qualcomm-ui-angular-core-slider.mjs +98 -102
- package/fesm2022/qualcomm-ui-angular-core-slider.mjs.map +1 -1
- package/fesm2022/qualcomm-ui-angular-core-state.mjs +5 -5
- package/fesm2022/qualcomm-ui-angular-core-state.mjs.map +1 -1
- package/fesm2022/qualcomm-ui-angular-core-switch.mjs +38 -40
- package/fesm2022/qualcomm-ui-angular-core-switch.mjs.map +1 -1
- package/fesm2022/qualcomm-ui-angular-core-tabs.mjs +51 -65
- package/fesm2022/qualcomm-ui-angular-core-tabs.mjs.map +1 -1
- package/fesm2022/qualcomm-ui-angular-core-text-area.mjs +34 -34
- package/fesm2022/qualcomm-ui-angular-core-text-area.mjs.map +1 -1
- package/fesm2022/qualcomm-ui-angular-core-text-input.mjs +37 -37
- package/fesm2022/qualcomm-ui-angular-core-text-input.mjs.map +1 -1
- package/fesm2022/qualcomm-ui-angular-core-toast.mjs +30 -30
- package/fesm2022/qualcomm-ui-angular-core-toast.mjs.map +1 -1
- package/fesm2022/qualcomm-ui-angular-core-tooltip.mjs +37 -45
- package/fesm2022/qualcomm-ui-angular-core-tooltip.mjs.map +1 -1
- package/fesm2022/qualcomm-ui-angular-core-tree.mjs +70 -78
- package/fesm2022/qualcomm-ui-angular-core-tree.mjs.map +1 -1
- package/fesm2022/qualcomm-ui-angular-core-virtual.mjs +5 -5
- package/fesm2022/qualcomm-ui-angular-core-virtual.mjs.map +1 -1
- package/package.json +57 -57
- package/{accordion/index.d.ts → types/qualcomm-ui-angular-core-accordion.d.ts} +1 -1
- package/types/qualcomm-ui-angular-core-accordion.d.ts.map +1 -0
- package/{attributes/index.d.ts → types/qualcomm-ui-angular-core-attributes.d.ts} +1 -1
- package/types/qualcomm-ui-angular-core-attributes.d.ts.map +1 -0
- package/{avatar/index.d.ts → types/qualcomm-ui-angular-core-avatar.d.ts} +1 -1
- package/types/qualcomm-ui-angular-core-avatar.d.ts.map +1 -0
- package/{checkbox/index.d.ts → types/qualcomm-ui-angular-core-checkbox.d.ts} +1 -1
- package/types/qualcomm-ui-angular-core-checkbox.d.ts.map +1 -0
- package/{collapsible/index.d.ts → types/qualcomm-ui-angular-core-collapsible.d.ts} +1 -1
- package/types/qualcomm-ui-angular-core-collapsible.d.ts.map +1 -0
- package/{collection/index.d.ts → types/qualcomm-ui-angular-core-collection.d.ts} +1 -1
- package/types/qualcomm-ui-angular-core-collection.d.ts.map +1 -0
- package/{combobox/index.d.ts → types/qualcomm-ui-angular-core-combobox.d.ts} +2 -2
- package/types/qualcomm-ui-angular-core-combobox.d.ts.map +1 -0
- package/{common/index.d.ts → types/qualcomm-ui-angular-core-common.d.ts} +1 -1
- package/types/qualcomm-ui-angular-core-common.d.ts.map +1 -0
- package/{dialog/index.d.ts → types/qualcomm-ui-angular-core-dialog.d.ts} +1 -1
- package/types/qualcomm-ui-angular-core-dialog.d.ts.map +1 -0
- package/{dom/index.d.ts → types/qualcomm-ui-angular-core-dom.d.ts} +1 -1
- package/types/qualcomm-ui-angular-core-dom.d.ts.map +1 -0
- package/{events/index.d.ts → types/qualcomm-ui-angular-core-events.d.ts} +1 -1
- package/types/qualcomm-ui-angular-core-events.d.ts.map +1 -0
- package/{forms/index.d.ts → types/qualcomm-ui-angular-core-forms.d.ts} +1 -1
- package/types/qualcomm-ui-angular-core-forms.d.ts.map +1 -0
- package/{highlight/index.d.ts → types/qualcomm-ui-angular-core-highlight.d.ts} +1 -1
- package/types/qualcomm-ui-angular-core-highlight.d.ts.map +1 -0
- package/{inline-notification/index.d.ts → types/qualcomm-ui-angular-core-inline-notification.d.ts} +1 -1
- package/types/qualcomm-ui-angular-core-inline-notification.d.ts.map +1 -0
- package/{input/index.d.ts → types/qualcomm-ui-angular-core-input.d.ts} +2 -2
- package/types/qualcomm-ui-angular-core-input.d.ts.map +1 -0
- package/{locale/index.d.ts → types/qualcomm-ui-angular-core-locale.d.ts} +1 -1
- package/types/qualcomm-ui-angular-core-locale.d.ts.map +1 -0
- package/{lorem-ipsum/index.d.ts → types/qualcomm-ui-angular-core-lorem-ipsum.d.ts} +1 -1
- package/types/qualcomm-ui-angular-core-lorem-ipsum.d.ts.map +1 -0
- package/{lucide/index.d.ts → types/qualcomm-ui-angular-core-lucide.d.ts} +1 -1
- package/types/qualcomm-ui-angular-core-lucide.d.ts.map +1 -0
- package/{machine/index.d.ts → types/qualcomm-ui-angular-core-machine.d.ts} +2 -2
- package/types/qualcomm-ui-angular-core-machine.d.ts.map +1 -0
- package/{menu/index.d.ts → types/qualcomm-ui-angular-core-menu.d.ts} +1 -1
- package/types/qualcomm-ui-angular-core-menu.d.ts.map +1 -0
- package/{number-input/index.d.ts → types/qualcomm-ui-angular-core-number-input.d.ts} +1 -1
- package/types/qualcomm-ui-angular-core-number-input.d.ts.map +1 -0
- package/{observers/index.d.ts → types/qualcomm-ui-angular-core-observers.d.ts} +1 -1
- package/types/qualcomm-ui-angular-core-observers.d.ts.map +1 -0
- package/{pagination/index.d.ts → types/qualcomm-ui-angular-core-pagination.d.ts} +1 -1
- package/types/qualcomm-ui-angular-core-pagination.d.ts.map +1 -0
- package/{password-input/index.d.ts → types/qualcomm-ui-angular-core-password-input.d.ts} +1 -1
- package/types/qualcomm-ui-angular-core-password-input.d.ts.map +1 -0
- package/{popover/index.d.ts → types/qualcomm-ui-angular-core-popover.d.ts} +1 -1
- package/types/qualcomm-ui-angular-core-popover.d.ts.map +1 -0
- package/{portal/index.d.ts → types/qualcomm-ui-angular-core-portal.d.ts} +1 -1
- package/types/qualcomm-ui-angular-core-portal.d.ts.map +1 -0
- package/{presence/index.d.ts → types/qualcomm-ui-angular-core-presence.d.ts} +1 -1
- package/types/qualcomm-ui-angular-core-presence.d.ts.map +1 -0
- package/{progress-ring/index.d.ts → types/qualcomm-ui-angular-core-progress-ring.d.ts} +1 -1
- package/types/qualcomm-ui-angular-core-progress-ring.d.ts.map +1 -0
- package/{progress/index.d.ts → types/qualcomm-ui-angular-core-progress.d.ts} +1 -1
- package/types/qualcomm-ui-angular-core-progress.d.ts.map +1 -0
- package/{radio/index.d.ts → types/qualcomm-ui-angular-core-radio.d.ts} +1 -1
- package/types/qualcomm-ui-angular-core-radio.d.ts.map +1 -0
- package/{segmented-control/index.d.ts → types/qualcomm-ui-angular-core-segmented-control.d.ts} +1 -1
- package/types/qualcomm-ui-angular-core-segmented-control.d.ts.map +1 -0
- package/{select/index.d.ts → types/qualcomm-ui-angular-core-select.d.ts} +1 -1
- package/types/qualcomm-ui-angular-core-select.d.ts.map +1 -0
- package/{side-nav/index.d.ts → types/qualcomm-ui-angular-core-side-nav.d.ts} +1 -1
- package/types/qualcomm-ui-angular-core-side-nav.d.ts.map +1 -0
- package/{signals/index.d.ts → types/qualcomm-ui-angular-core-signals.d.ts} +1 -1
- package/types/qualcomm-ui-angular-core-signals.d.ts.map +1 -0
- package/{slider/index.d.ts → types/qualcomm-ui-angular-core-slider.d.ts} +1 -1
- package/types/qualcomm-ui-angular-core-slider.d.ts.map +1 -0
- package/{state/index.d.ts → types/qualcomm-ui-angular-core-state.d.ts} +1 -1
- package/types/qualcomm-ui-angular-core-state.d.ts.map +1 -0
- package/{switch/index.d.ts → types/qualcomm-ui-angular-core-switch.d.ts} +1 -1
- package/types/qualcomm-ui-angular-core-switch.d.ts.map +1 -0
- package/{tabs/index.d.ts → types/qualcomm-ui-angular-core-tabs.d.ts} +1 -1
- package/types/qualcomm-ui-angular-core-tabs.d.ts.map +1 -0
- package/{text-area/index.d.ts → types/qualcomm-ui-angular-core-text-area.d.ts} +1 -1
- package/types/qualcomm-ui-angular-core-text-area.d.ts.map +1 -0
- package/{text-input/index.d.ts → types/qualcomm-ui-angular-core-text-input.d.ts} +1 -1
- package/types/qualcomm-ui-angular-core-text-input.d.ts.map +1 -0
- package/{toast/index.d.ts → types/qualcomm-ui-angular-core-toast.d.ts} +1 -1
- package/types/qualcomm-ui-angular-core-toast.d.ts.map +1 -0
- package/{tooltip/index.d.ts → types/qualcomm-ui-angular-core-tooltip.d.ts} +1 -1
- package/types/qualcomm-ui-angular-core-tooltip.d.ts.map +1 -0
- package/{tree/index.d.ts → types/qualcomm-ui-angular-core-tree.d.ts} +1 -1
- package/types/qualcomm-ui-angular-core-tree.d.ts.map +1 -0
- package/{virtual/index.d.ts → types/qualcomm-ui-angular-core-virtual.d.ts} +1 -1
- package/types/qualcomm-ui-angular-core-virtual.d.ts.map +1 -0
- package/types/qualcomm-ui-angular-core.d.ts +3 -0
- package/types/qualcomm-ui-angular-core.d.ts.map +1 -0
- package/accordion/index.d.ts.map +0 -1
- package/attributes/index.d.ts.map +0 -1
- package/avatar/index.d.ts.map +0 -1
- package/checkbox/index.d.ts.map +0 -1
- package/collapsible/index.d.ts.map +0 -1
- package/collection/index.d.ts.map +0 -1
- package/combobox/index.d.ts.map +0 -1
- package/common/index.d.ts.map +0 -1
- package/dialog/index.d.ts.map +0 -1
- package/dom/index.d.ts.map +0 -1
- package/events/index.d.ts.map +0 -1
- package/forms/index.d.ts.map +0 -1
- package/highlight/index.d.ts.map +0 -1
- package/index.d.ts +0 -3
- package/index.d.ts.map +0 -1
- package/inline-notification/index.d.ts.map +0 -1
- package/input/index.d.ts.map +0 -1
- package/locale/index.d.ts.map +0 -1
- package/lorem-ipsum/index.d.ts.map +0 -1
- package/lucide/index.d.ts.map +0 -1
- package/machine/index.d.ts.map +0 -1
- package/menu/index.d.ts.map +0 -1
- package/number-input/index.d.ts.map +0 -1
- package/observers/index.d.ts.map +0 -1
- package/pagination/index.d.ts.map +0 -1
- package/password-input/index.d.ts.map +0 -1
- package/popover/index.d.ts.map +0 -1
- package/portal/index.d.ts.map +0 -1
- package/presence/index.d.ts.map +0 -1
- package/progress/index.d.ts.map +0 -1
- package/progress-ring/index.d.ts.map +0 -1
- package/radio/index.d.ts.map +0 -1
- package/segmented-control/index.d.ts.map +0 -1
- package/select/index.d.ts.map +0 -1
- package/side-nav/index.d.ts.map +0 -1
- package/signals/index.d.ts.map +0 -1
- package/slider/index.d.ts.map +0 -1
- package/state/index.d.ts.map +0 -1
- package/switch/index.d.ts.map +0 -1
- package/tabs/index.d.ts.map +0 -1
- package/text-area/index.d.ts.map +0 -1
- package/text-input/index.d.ts.map +0 -1
- package/toast/index.d.ts.map +0 -1
- package/tooltip/index.d.ts.map +0 -1
- package/tree/index.d.ts.map +0 -1
- package/virtual/index.d.ts.map +0 -1
|
@@ -83,8 +83,8 @@ class ClipboardService {
|
|
|
83
83
|
get copied() {
|
|
84
84
|
return this._copied.asReadonly();
|
|
85
85
|
}
|
|
86
|
-
_copied = signal(false, ...(ngDevMode ? [{ debugName: "_copied" }] : []));
|
|
87
|
-
icon = computed(() => this.copied() ? Check : Copy, ...(ngDevMode ? [{ debugName: "icon" }] : []));
|
|
86
|
+
_copied = signal(false, ...(ngDevMode ? [{ debugName: "_copied" }] : /* istanbul ignore next */ []));
|
|
87
|
+
icon = computed(() => this.copied() ? Check : Copy, ...(ngDevMode ? [{ debugName: "icon" }] : /* istanbul ignore next */ []));
|
|
88
88
|
copyTimeout;
|
|
89
89
|
navigator = inject(NAVIGATOR);
|
|
90
90
|
platformId = inject(PLATFORM_ID);
|
|
@@ -103,10 +103,10 @@ class ClipboardService {
|
|
|
103
103
|
}, timeout);
|
|
104
104
|
return this.navigator.clipboard.writeText(text).then(() => text);
|
|
105
105
|
}
|
|
106
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
107
|
-
static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "
|
|
106
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.2", ngImport: i0, type: ClipboardService, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
|
|
107
|
+
static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.2.2", ngImport: i0, type: ClipboardService });
|
|
108
108
|
}
|
|
109
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
109
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.2", ngImport: i0, type: ClipboardService, decorators: [{
|
|
110
110
|
type: Injectable
|
|
111
111
|
}] });
|
|
112
112
|
|
|
@@ -139,7 +139,7 @@ class DescendantsManagerService extends DescendantsManager {
|
|
|
139
139
|
get subscribe() {
|
|
140
140
|
return this._subscribe.asReadonly();
|
|
141
141
|
}
|
|
142
|
-
_subscribe = signal(0, ...(ngDevMode ? [{ debugName: "_subscribe" }] : []));
|
|
142
|
+
_subscribe = signal(0, ...(ngDevMode ? [{ debugName: "_subscribe" }] : /* istanbul ignore next */ []));
|
|
143
143
|
emit() {
|
|
144
144
|
this._subscribe.update((prev) => prev + 1);
|
|
145
145
|
}
|
|
@@ -151,10 +151,10 @@ class DescendantsManagerService extends DescendantsManager {
|
|
|
151
151
|
super.unregister(node);
|
|
152
152
|
untracked(() => this.emit());
|
|
153
153
|
}
|
|
154
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
155
|
-
static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "
|
|
154
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.2", ngImport: i0, type: DescendantsManagerService, deps: null, target: i0.ɵɵFactoryTarget.Injectable });
|
|
155
|
+
static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.2.2", ngImport: i0, type: DescendantsManagerService });
|
|
156
156
|
}
|
|
157
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
157
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.2", ngImport: i0, type: DescendantsManagerService, decorators: [{
|
|
158
158
|
type: Injectable
|
|
159
159
|
}] });
|
|
160
160
|
|
|
@@ -205,10 +205,10 @@ class IdService {
|
|
|
205
205
|
}
|
|
206
206
|
return `${componentName}::auto-id::${this.ids[componentName]++}`;
|
|
207
207
|
}
|
|
208
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
209
|
-
static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "
|
|
208
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.2", ngImport: i0, type: IdService, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
|
|
209
|
+
static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.2.2", ngImport: i0, type: IdService, providedIn: "root" });
|
|
210
210
|
}
|
|
211
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
211
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.2", ngImport: i0, type: IdService, decorators: [{
|
|
212
212
|
type: Injectable,
|
|
213
213
|
args: [{ providedIn: "root" }]
|
|
214
214
|
}] });
|
|
@@ -220,10 +220,10 @@ class PortalConfigService {
|
|
|
220
220
|
get portalNodeId() {
|
|
221
221
|
return this._portalNodeId;
|
|
222
222
|
}
|
|
223
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
224
|
-
static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "
|
|
223
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.2", ngImport: i0, type: PortalConfigService, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
|
|
224
|
+
static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.2.2", ngImport: i0, type: PortalConfigService, providedIn: "root" });
|
|
225
225
|
}
|
|
226
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
226
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.2", ngImport: i0, type: PortalConfigService, decorators: [{
|
|
227
227
|
type: Injectable,
|
|
228
228
|
args: [{ providedIn: "root" }]
|
|
229
229
|
}] });
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"qualcomm-ui-angular-core-dom.mjs","sources":["../../src/dom/tokens/window.ts","../../src/dom/tokens/caches.ts","../../src/dom/tokens/css.ts","../../src/dom/tokens/local-storage.ts","../../src/dom/tokens/location.ts","../../src/dom/tokens/navigator.ts","../../src/dom/tokens/media-devices.ts","../../src/dom/tokens/performance.ts","../../src/dom/tokens/screen.ts","../../src/dom/tokens/user-agent.ts","../../src/dom/clipboard.service.ts","../../src/dom/context-id-signal.ts","../../src/dom/descendants-manager.service.ts","../../src/dom/element-id-signal.ts","../../src/dom/id.service.ts","../../src/dom/portal-config.service.ts","../../src/dom/qualcomm-ui-angular-core-dom.ts"],"sourcesContent":["// Copyright (c) Qualcomm Technologies, Inc. and/or its subsidiaries.\n// SPDX-License-Identifier: BSD-3-Clause-Clear\n\nimport {DOCUMENT} from \"@angular/common\"\nimport {inject, InjectionToken} from \"@angular/core\"\n\nexport const WINDOW = new InjectionToken<Window>(\n \"An abstraction over global window object\",\n {\n factory: () => {\n const {defaultView} = inject(DOCUMENT)\n\n if (!defaultView) {\n throw new Error(\"Window is not available\")\n }\n\n return defaultView\n },\n },\n)\n","// Copyright (c) Qualcomm Technologies, Inc. and/or its subsidiaries.\n// SPDX-License-Identifier: BSD-3-Clause-Clear\n\nimport {inject, InjectionToken} from \"@angular/core\"\n\nimport {WINDOW} from \"./window\"\n\nexport const CACHES = new InjectionToken<CacheStorage>(\n \"An abstraction over window.caches object\",\n {\n factory: () => inject(WINDOW).caches,\n },\n)\n","// Copyright (c) Qualcomm Technologies, Inc. and/or its subsidiaries.\n// SPDX-License-Identifier: BSD-3-Clause-Clear\n\nimport {inject, InjectionToken} from \"@angular/core\"\n\nimport {WINDOW} from \"./window\"\n\n/**\n * Use Window['CSS'], this is a workaround to support Angular 6+\n */\ninterface Css {\n escape(ident: string): string\n supports(property: string, value: string): boolean\n supports(conditionText: string): boolean\n}\n\nexport const CSS = new InjectionToken<Css>(\n \"An abstraction over window.CSS object\",\n {\n factory: () =>\n (inject(WINDOW) as any).CSS || {\n escape: (v) => v,\n supports: () => false,\n },\n },\n)\n","// Copyright (c) Qualcomm Technologies, Inc. and/or its subsidiaries.\n// SPDX-License-Identifier: BSD-3-Clause-Clear\n\nimport {inject, InjectionToken} from \"@angular/core\"\n\nimport {WINDOW} from \"./window\"\n\nexport const LOCAL_STORAGE = new InjectionToken<Storage>(\n \"An abstraction over window.localStorage object\",\n {\n factory: () => inject(WINDOW).localStorage,\n },\n)\n","// Copyright (c) Qualcomm Technologies, Inc. and/or its subsidiaries.\n// SPDX-License-Identifier: BSD-3-Clause-Clear\n\nimport {inject, InjectionToken} from \"@angular/core\"\n\nimport {WINDOW} from \"./window\"\n\nexport const LOCATION = new InjectionToken<Location>(\n \"An abstraction over window.location object\",\n {\n factory: () => inject(WINDOW).location,\n },\n)\n","// Copyright (c) Qualcomm Technologies, Inc. and/or its subsidiaries.\n// SPDX-License-Identifier: BSD-3-Clause-Clear\n\nimport {inject, InjectionToken} from \"@angular/core\"\n\nimport {WINDOW} from \"./window\"\n\nexport const NAVIGATOR = new InjectionToken<Navigator>(\n \"An abstraction over window.navigator object\",\n {\n factory: () => inject(WINDOW).navigator,\n },\n)\n","// Copyright (c) Qualcomm Technologies, Inc. and/or its subsidiaries.\n// SPDX-License-Identifier: BSD-3-Clause-Clear\n\nimport {inject, InjectionToken} from \"@angular/core\"\n\nimport {NAVIGATOR} from \"./navigator\"\n\nexport const MEDIA_DEVICES = new InjectionToken<MediaDevices>(\n \"An abstraction over window.navigator.mediaDevices object\",\n {\n factory: () => inject(NAVIGATOR).mediaDevices,\n },\n)\n","// Copyright (c) Qualcomm Technologies, Inc. and/or its subsidiaries.\n// SPDX-License-Identifier: BSD-3-Clause-Clear\n\nimport {inject, InjectionToken} from \"@angular/core\"\n\nimport {WINDOW} from \"./window\"\n\nexport const PERFORMANCE = new InjectionToken<Performance>(\n \"An abstraction over window.performance object\",\n {\n factory: () => inject(WINDOW).performance,\n },\n)\n","// Copyright (c) Qualcomm Technologies, Inc. and/or its subsidiaries.\n// SPDX-License-Identifier: BSD-3-Clause-Clear\n\nimport {inject, InjectionToken} from \"@angular/core\"\n\nimport {WINDOW} from \"./window\"\n\nexport const SCREEN = new InjectionToken<Screen>(\n \"An abstraction over window.screen object\",\n {\n factory: () => inject(WINDOW).screen,\n },\n)\n","// Copyright (c) Qualcomm Technologies, Inc. and/or its subsidiaries.\n// SPDX-License-Identifier: BSD-3-Clause-Clear\n\nimport {inject, InjectionToken} from \"@angular/core\"\n\nimport {NAVIGATOR} from \"./navigator\"\n\nexport const USER_AGENT = new InjectionToken<string>(\n \"An abstraction over window.navigator.userAgent object\",\n {\n factory: () => inject(NAVIGATOR).userAgent,\n },\n)\n","// Copyright (c) Qualcomm Technologies, Inc. and/or its subsidiaries.\n// SPDX-License-Identifier: BSD-3-Clause-Clear\n\nimport {isPlatformServer} from \"@angular/common\"\nimport {\n computed,\n inject,\n Injectable,\n type OnDestroy,\n PLATFORM_ID,\n type Signal,\n signal,\n} from \"@angular/core\"\nimport {Check, Copy} from \"lucide-angular\"\n\nimport type {LucideIcon} from \"@qualcomm-ui/angular-core/lucide\"\n\nimport {NAVIGATOR} from \"./tokens\"\n\n/**\n * A simple helper service for copying text to the user's clipboard. SSR-safe,\n * debounce support, and optional icon support.\n */\n@Injectable()\nexport class ClipboardService implements OnDestroy {\n get copied() {\n return this._copied.asReadonly()\n }\n private readonly _copied = signal<boolean>(false)\n\n readonly icon: Signal<LucideIcon> = computed(() =>\n this.copied() ? Check : Copy,\n )\n\n private copyTimeout: ReturnType<typeof setTimeout>\n\n private navigator = inject(NAVIGATOR)\n private platformId = inject(PLATFORM_ID)\n\n ngOnDestroy() {\n clearTimeout(this.copyTimeout)\n }\n\n async copy(text: string, timeout = 1200) {\n // debounce\n if (this.copied() || isPlatformServer(this.platformId)) {\n return undefined\n }\n // show an indicator that the copy action succeeded\n this._copied.set(true)\n this.copyTimeout = setTimeout(() => {\n this._copied.set(false)\n }, timeout)\n\n return this.navigator.clipboard.writeText(text).then(() => text)\n }\n}\n","// Copyright (c) Qualcomm Technologies, Inc. and/or its subsidiaries.\n// SPDX-License-Identifier: BSD-3-Clause-Clear\n\nimport {\n type CreateSignalOptions,\n signal,\n type WritableSignal,\n} from \"@angular/core\"\n\nexport type ContextIdSignal = WritableSignal<string> & {\n /**\n * Retrieves the id string, or undefined if it is empty. When you bind `undefined`\n * to an attribute in Angular, the attribute is removed from the DOM element.\n *\n * @example\n *\n * ```ts\n * @Component({\n * template: `\n * <div id=\"1\" [attr.aria-labelledby]=\"emptyId\"></div>\n * <div id=\"2\" [attr.aria-labelledby]=\"undefinedId\"></div>\n * `\n * })\n * class Component {\n * emptyId = \"\"\n * undefinedId = undefined\n * }\n *```\n *\n *```html\n * <!-- resulting DOM elements: -->\n * <!-- invalid DOM element: aria-labelledby must be set if defined -->\n * <div id=\"1\" aria-labelledby></div>\n *\n * <!-- valid DOM element -->\n * <div id=\"2\"></div>\n *```\n */\n asAttribute(): string | undefined\n\n set(value: string, onDestroy?: (callback: () => void) => void): void\n}\n\n/**\n * A simple wrapper around a signal for tracking an element's id in a shared\n * service. This signal resets the value when its element's reference is destroyed.\n *\n * @param initialValue\n * @param options\n */\nexport function contextIdSignal(\n initialValue?: string,\n options?: CreateSignalOptions<string | undefined>,\n) {\n const signalFn = signal(initialValue, options)\n const setter = signalFn.set\n\n ;(signalFn as unknown as ContextIdSignal).asAttribute = () =>\n signalFn() || undefined\n ;(signalFn as unknown as any).set = (\n value: string | undefined,\n onDestroy?: (callback: () => void) => void,\n ) => {\n onDestroy?.(() => {\n setter(initialValue)\n })\n setter(value)\n }\n\n return signalFn as ContextIdSignal\n}\n","// Copyright (c) Qualcomm Technologies, Inc. and/or its subsidiaries.\n// SPDX-License-Identifier: BSD-3-Clause-Clear\n\nimport {Injectable, signal, untracked} from \"@angular/core\"\n\nimport {\n type DescendantOptions,\n DescendantsManager,\n} from \"@qualcomm-ui/utils/descendants\"\n\n@Injectable()\nexport class DescendantsManagerService<\n T extends HTMLElement,\n K extends Record<string, any> = object,\n> extends DescendantsManager<T, K> {\n // simple signal for consumers to subscribe to changes.\n get subscribe() {\n return this._subscribe.asReadonly()\n }\n\n private readonly _subscribe = signal<number>(0)\n\n emit() {\n this._subscribe.update((prev) => prev + 1)\n }\n\n override register(nodeOrOptions: T | null | DescendantOptions<K>) {\n super.register(nodeOrOptions)\n untracked(() => this.emit())\n }\n\n override unregister(node: T) {\n super.unregister(node)\n untracked(() => this.emit())\n }\n}\n","// Copyright (c) Qualcomm Technologies, Inc. and/or its subsidiaries.\n// SPDX-License-Identifier: BSD-3-Clause-Clear\n\nimport {\n type CreateSignalOptions,\n type DestroyRef,\n signal,\n type WritableSignal,\n} from \"@angular/core\"\n\nexport type ElementIdSignal = WritableSignal<string> & {\n /**\n * Retrieves the id string, or undefined if it is empty. When you bind `undefined`\n * to an attribute in Angular, the attribute is removed from the DOM element.\n *\n * @example\n *\n * ```ts\n * @Component({\n * template: `\n * <div id=\"1\" [attr.aria-labelledby]=\"emptyId\"></div>\n * <div id=\"2\" [attr.aria-labelledby]=\"undefinedId\"></div>\n * `\n * })\n * class Component {\n * emptyId = \"\"\n * undefinedId = undefined\n * }\n *```\n *\n *```html\n * <!-- resulting DOM elements: -->\n * <!-- invalid DOM element: aria-labelledby must be set if defined -->\n * <div id=\"1\" aria-labelledby></div>\n *\n * <!-- valid DOM element -->\n * <div id=\"2\"></div>\n *```\n */\n asAttribute(): string | undefined\n\n set(value: string, destroyRef: DestroyRef): void\n}\n\n/**\n * A simple wrapper around a signal for tracking an element's id in a shared\n * service. This signal resets the value when its element's reference is destroyed.\n *\n * @param initialValue\n * @param options\n */\nexport function elementIdSignal(\n initialValue?: string,\n options?: CreateSignalOptions<string | undefined>,\n) {\n const signalFn = signal(initialValue, options)\n const setter = signalFn.set\n\n ;(signalFn as unknown as ElementIdSignal).asAttribute = () =>\n signalFn() || undefined\n ;(signalFn as unknown as any).set = (\n value: string | undefined,\n destroyRef: DestroyRef,\n ) => {\n onElementDestroyed()\n onElementDestroyed = destroyRef.onDestroy(() => {\n setter(initialValue)\n })\n setter(value)\n }\n\n let onElementDestroyed = () => {}\n\n return signalFn as ElementIdSignal\n}\n","// Copyright (c) Qualcomm Technologies, Inc. and/or its subsidiaries.\n// SPDX-License-Identifier: BSD-3-Clause-Clear\n\nimport {Injectable} from \"@angular/core\"\n\n/**\n * Simple service that can persist IDs across from SSR to CSR.\n */\n@Injectable({providedIn: \"root\"})\nexport class IdService {\n private ids: Record<string, number> = {}\n\n useId(\n componentName: string,\n idProp: string | undefined | null,\n idAttr: string | null,\n ) {\n // only use the supplied id if it does not also map to an attribute. This is a\n // workaround because we are using the `id` prop. If supplied as `[id]`, it\n // will work as expected. If supplied as `[attr.id]` or `id`, it will be treated\n // as an attribute. When this happens, we do not use the supplied id and instead\n // generate one. Otherwise, we'd get two ID's in the DOM (one on the host\n // element and one on the internal element that we bind the id to).\n const id = idProp || idAttr\n if (id) {\n return id\n }\n if (!this.ids[componentName]) {\n this.ids[componentName] = 1\n }\n return `${componentName}::auto-id::${this.ids[componentName]++}`\n }\n}\n","// Copyright (c) Qualcomm Technologies, Inc. and/or its subsidiaries.\n// SPDX-License-Identifier: BSD-3-Clause-Clear\n\nimport {Injectable} from \"@angular/core\"\n\n@Injectable({providedIn: \"root\"})\nexport class PortalConfigService {\n private _portalNodeId = \"q-portal-root\"\n\n get portalNodeId() {\n return this._portalNodeId\n }\n}\n","/**\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ts","../../src/dom/tokens/local-storage.ts","../../src/dom/tokens/location.ts","../../src/dom/tokens/navigator.ts","../../src/dom/tokens/media-devices.ts","../../src/dom/tokens/performance.ts","../../src/dom/tokens/screen.ts","../../src/dom/tokens/user-agent.ts","../../src/dom/clipboard.service.ts","../../src/dom/context-id-signal.ts","../../src/dom/descendants-manager.service.ts","../../src/dom/element-id-signal.ts","../../src/dom/id.service.ts","../../src/dom/portal-config.service.ts","../../src/dom/qualcomm-ui-angular-core-dom.ts"],"sourcesContent":["// Copyright (c) Qualcomm Technologies, Inc. and/or its subsidiaries.\n// SPDX-License-Identifier: BSD-3-Clause-Clear\n\nimport {DOCUMENT} from \"@angular/common\"\nimport {inject, InjectionToken} from \"@angular/core\"\n\nexport const WINDOW = new InjectionToken<Window>(\n \"An abstraction over global window object\",\n {\n factory: () => {\n const {defaultView} = inject(DOCUMENT)\n\n if (!defaultView) {\n throw new Error(\"Window is not available\")\n }\n\n return defaultView\n },\n },\n)\n","// Copyright (c) Qualcomm Technologies, Inc. and/or its subsidiaries.\n// SPDX-License-Identifier: BSD-3-Clause-Clear\n\nimport {inject, InjectionToken} from \"@angular/core\"\n\nimport {WINDOW} from \"./window\"\n\nexport const CACHES = new InjectionToken<CacheStorage>(\n \"An abstraction over window.caches object\",\n {\n factory: () => inject(WINDOW).caches,\n },\n)\n","// Copyright (c) Qualcomm Technologies, Inc. and/or its subsidiaries.\n// SPDX-License-Identifier: BSD-3-Clause-Clear\n\nimport {inject, InjectionToken} from \"@angular/core\"\n\nimport {WINDOW} from \"./window\"\n\n/**\n * Use Window['CSS'], this is a workaround to support Angular 6+\n */\ninterface Css {\n escape(ident: string): string\n supports(property: string, value: string): boolean\n supports(conditionText: string): boolean\n}\n\nexport const CSS = new InjectionToken<Css>(\n \"An abstraction over window.CSS object\",\n {\n factory: () =>\n (inject(WINDOW) as any).CSS || {\n escape: (v) => v,\n supports: () => false,\n },\n },\n)\n","// Copyright (c) Qualcomm Technologies, Inc. and/or its subsidiaries.\n// SPDX-License-Identifier: BSD-3-Clause-Clear\n\nimport {inject, InjectionToken} from \"@angular/core\"\n\nimport {WINDOW} from \"./window\"\n\nexport const LOCAL_STORAGE = new InjectionToken<Storage>(\n \"An abstraction over window.localStorage object\",\n {\n factory: () => inject(WINDOW).localStorage,\n },\n)\n","// Copyright (c) Qualcomm Technologies, Inc. and/or its subsidiaries.\n// SPDX-License-Identifier: BSD-3-Clause-Clear\n\nimport {inject, InjectionToken} from \"@angular/core\"\n\nimport {WINDOW} from \"./window\"\n\nexport const LOCATION = new InjectionToken<Location>(\n \"An abstraction over window.location object\",\n {\n factory: () => inject(WINDOW).location,\n },\n)\n","// Copyright (c) Qualcomm Technologies, Inc. and/or its subsidiaries.\n// SPDX-License-Identifier: BSD-3-Clause-Clear\n\nimport {inject, InjectionToken} from \"@angular/core\"\n\nimport {WINDOW} from \"./window\"\n\nexport const NAVIGATOR = new InjectionToken<Navigator>(\n \"An abstraction over window.navigator object\",\n {\n factory: () => inject(WINDOW).navigator,\n },\n)\n","// Copyright (c) Qualcomm Technologies, Inc. and/or its subsidiaries.\n// SPDX-License-Identifier: BSD-3-Clause-Clear\n\nimport {inject, InjectionToken} from \"@angular/core\"\n\nimport {NAVIGATOR} from \"./navigator\"\n\nexport const MEDIA_DEVICES = new InjectionToken<MediaDevices>(\n \"An abstraction over window.navigator.mediaDevices object\",\n {\n factory: () => inject(NAVIGATOR).mediaDevices,\n },\n)\n","// Copyright (c) Qualcomm Technologies, Inc. and/or its subsidiaries.\n// SPDX-License-Identifier: BSD-3-Clause-Clear\n\nimport {inject, InjectionToken} from \"@angular/core\"\n\nimport {WINDOW} from \"./window\"\n\nexport const PERFORMANCE = new InjectionToken<Performance>(\n \"An abstraction over window.performance object\",\n {\n factory: () => inject(WINDOW).performance,\n },\n)\n","// Copyright (c) Qualcomm Technologies, Inc. and/or its subsidiaries.\n// SPDX-License-Identifier: BSD-3-Clause-Clear\n\nimport {inject, InjectionToken} from \"@angular/core\"\n\nimport {WINDOW} from \"./window\"\n\nexport const SCREEN = new InjectionToken<Screen>(\n \"An abstraction over window.screen object\",\n {\n factory: () => inject(WINDOW).screen,\n },\n)\n","// Copyright (c) Qualcomm Technologies, Inc. and/or its subsidiaries.\n// SPDX-License-Identifier: BSD-3-Clause-Clear\n\nimport {inject, InjectionToken} from \"@angular/core\"\n\nimport {NAVIGATOR} from \"./navigator\"\n\nexport const USER_AGENT = new InjectionToken<string>(\n \"An abstraction over window.navigator.userAgent object\",\n {\n factory: () => inject(NAVIGATOR).userAgent,\n },\n)\n","// Copyright (c) Qualcomm Technologies, Inc. and/or its subsidiaries.\n// SPDX-License-Identifier: BSD-3-Clause-Clear\n\nimport {isPlatformServer} from \"@angular/common\"\nimport {\n computed,\n inject,\n Injectable,\n type OnDestroy,\n PLATFORM_ID,\n type Signal,\n signal,\n} from \"@angular/core\"\nimport {Check, Copy} from \"lucide-angular\"\n\nimport type {LucideIcon} from \"@qualcomm-ui/angular-core/lucide\"\n\nimport {NAVIGATOR} from \"./tokens\"\n\n/**\n * A simple helper service for copying text to the user's clipboard. SSR-safe,\n * debounce support, and optional icon support.\n */\n@Injectable()\nexport class ClipboardService implements OnDestroy {\n get copied() {\n return this._copied.asReadonly()\n }\n private readonly _copied = signal<boolean>(false)\n\n readonly icon: Signal<LucideIcon> = computed(() =>\n this.copied() ? Check : Copy,\n )\n\n private copyTimeout: ReturnType<typeof setTimeout>\n\n private navigator = inject(NAVIGATOR)\n private platformId = inject(PLATFORM_ID)\n\n ngOnDestroy() {\n clearTimeout(this.copyTimeout)\n }\n\n async copy(text: string, timeout = 1200) {\n // debounce\n if (this.copied() || isPlatformServer(this.platformId)) {\n return undefined\n }\n // show an indicator that the copy action succeeded\n this._copied.set(true)\n this.copyTimeout = setTimeout(() => {\n this._copied.set(false)\n }, timeout)\n\n return this.navigator.clipboard.writeText(text).then(() => text)\n }\n}\n","// Copyright (c) Qualcomm Technologies, Inc. and/or its subsidiaries.\n// SPDX-License-Identifier: BSD-3-Clause-Clear\n\nimport {\n type CreateSignalOptions,\n signal,\n type WritableSignal,\n} from \"@angular/core\"\n\nexport type ContextIdSignal = WritableSignal<string> & {\n /**\n * Retrieves the id string, or undefined if it is empty. When you bind `undefined`\n * to an attribute in Angular, the attribute is removed from the DOM element.\n *\n * @example\n *\n * ```ts\n * @Component({\n * template: `\n * <div id=\"1\" [attr.aria-labelledby]=\"emptyId\"></div>\n * <div id=\"2\" [attr.aria-labelledby]=\"undefinedId\"></div>\n * `\n * })\n * class Component {\n * emptyId = \"\"\n * undefinedId = undefined\n * }\n *```\n *\n *```html\n * <!-- resulting DOM elements: -->\n * <!-- invalid DOM element: aria-labelledby must be set if defined -->\n * <div id=\"1\" aria-labelledby></div>\n *\n * <!-- valid DOM element -->\n * <div id=\"2\"></div>\n *```\n */\n asAttribute(): string | undefined\n\n set(value: string, onDestroy?: (callback: () => void) => void): void\n}\n\n/**\n * A simple wrapper around a signal for tracking an element's id in a shared\n * service. This signal resets the value when its element's reference is destroyed.\n *\n * @param initialValue\n * @param options\n */\nexport function contextIdSignal(\n initialValue?: string,\n options?: CreateSignalOptions<string | undefined>,\n) {\n const signalFn = signal(initialValue, options)\n const setter = signalFn.set\n\n ;(signalFn as unknown as ContextIdSignal).asAttribute = () =>\n signalFn() || undefined\n ;(signalFn as unknown as any).set = (\n value: string | undefined,\n onDestroy?: (callback: () => void) => void,\n ) => {\n onDestroy?.(() => {\n setter(initialValue)\n })\n setter(value)\n }\n\n return signalFn as ContextIdSignal\n}\n","// Copyright (c) Qualcomm Technologies, Inc. and/or its subsidiaries.\n// SPDX-License-Identifier: BSD-3-Clause-Clear\n\nimport {Injectable, signal, untracked} from \"@angular/core\"\n\nimport {\n type DescendantOptions,\n DescendantsManager,\n} from \"@qualcomm-ui/utils/descendants\"\n\n@Injectable()\nexport class DescendantsManagerService<\n T extends HTMLElement,\n K extends Record<string, any> = object,\n> extends DescendantsManager<T, K> {\n // simple signal for consumers to subscribe to changes.\n get subscribe() {\n return this._subscribe.asReadonly()\n }\n\n private readonly _subscribe = signal<number>(0)\n\n emit() {\n this._subscribe.update((prev) => prev + 1)\n }\n\n override register(nodeOrOptions: T | null | DescendantOptions<K>) {\n super.register(nodeOrOptions)\n untracked(() => this.emit())\n }\n\n override unregister(node: T) {\n super.unregister(node)\n untracked(() => this.emit())\n }\n}\n","// Copyright (c) Qualcomm Technologies, Inc. and/or its subsidiaries.\n// SPDX-License-Identifier: BSD-3-Clause-Clear\n\nimport {\n type CreateSignalOptions,\n type DestroyRef,\n signal,\n type WritableSignal,\n} from \"@angular/core\"\n\nexport type ElementIdSignal = WritableSignal<string> & {\n /**\n * Retrieves the id string, or undefined if it is empty. When you bind `undefined`\n * to an attribute in Angular, the attribute is removed from the DOM element.\n *\n * @example\n *\n * ```ts\n * @Component({\n * template: `\n * <div id=\"1\" [attr.aria-labelledby]=\"emptyId\"></div>\n * <div id=\"2\" [attr.aria-labelledby]=\"undefinedId\"></div>\n * `\n * })\n * class Component {\n * emptyId = \"\"\n * undefinedId = undefined\n * }\n *```\n *\n *```html\n * <!-- resulting DOM elements: -->\n * <!-- invalid DOM element: aria-labelledby must be set if defined -->\n * <div id=\"1\" aria-labelledby></div>\n *\n * <!-- valid DOM element -->\n * <div id=\"2\"></div>\n *```\n */\n asAttribute(): string | undefined\n\n set(value: string, destroyRef: DestroyRef): void\n}\n\n/**\n * A simple wrapper around a signal for tracking an element's id in a shared\n * service. This signal resets the value when its element's reference is destroyed.\n *\n * @param initialValue\n * @param options\n */\nexport function elementIdSignal(\n initialValue?: string,\n options?: CreateSignalOptions<string | undefined>,\n) {\n const signalFn = signal(initialValue, options)\n const setter = signalFn.set\n\n ;(signalFn as unknown as ElementIdSignal).asAttribute = () =>\n signalFn() || undefined\n ;(signalFn as unknown as any).set = (\n value: string | undefined,\n destroyRef: DestroyRef,\n ) => {\n onElementDestroyed()\n onElementDestroyed = destroyRef.onDestroy(() => {\n setter(initialValue)\n })\n setter(value)\n }\n\n let onElementDestroyed = () => {}\n\n return signalFn as ElementIdSignal\n}\n","// Copyright (c) Qualcomm Technologies, Inc. and/or its subsidiaries.\n// SPDX-License-Identifier: BSD-3-Clause-Clear\n\nimport {Injectable} from \"@angular/core\"\n\n/**\n * Simple service that can persist IDs across from SSR to CSR.\n */\n@Injectable({providedIn: \"root\"})\nexport class IdService {\n private ids: Record<string, number> = {}\n\n useId(\n componentName: string,\n idProp: string | undefined | null,\n idAttr: string | null,\n ) {\n // only use the supplied id if it does not also map to an attribute. This is a\n // workaround because we are using the `id` prop. If supplied as `[id]`, it\n // will work as expected. If supplied as `[attr.id]` or `id`, it will be treated\n // as an attribute. When this happens, we do not use the supplied id and instead\n // generate one. Otherwise, we'd get two ID's in the DOM (one on the host\n // element and one on the internal element that we bind the id to).\n const id = idProp || idAttr\n if (id) {\n return id\n }\n if (!this.ids[componentName]) {\n this.ids[componentName] = 1\n }\n return `${componentName}::auto-id::${this.ids[componentName]++}`\n }\n}\n","// Copyright (c) Qualcomm Technologies, Inc. and/or its subsidiaries.\n// SPDX-License-Identifier: BSD-3-Clause-Clear\n\nimport {Injectable} from \"@angular/core\"\n\n@Injectable({providedIn: \"root\"})\nexport class PortalConfigService {\n private _portalNodeId = \"q-portal-root\"\n\n get portalNodeId() {\n return this._portalNodeId\n }\n}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;;AAAA;AACA;MAKa,MAAM,GAAG,IAAI,cAAc,CACtC,0CAA0C,EAC1C;IACE,OAAO,EAAE,MAAK;QACZ,MAAM,EAAC,WAAW,EAAC,GAAG,MAAM,CAAC,QAAQ,CAAC;QAEtC,IAAI,CAAC,WAAW,EAAE;AAChB,YAAA,MAAM,IAAI,KAAK,CAAC,yBAAyB,CAAC;QAC5C;AAEA,QAAA,OAAO,WAAW;IACpB,CAAC;AACF,CAAA;;AClBH;AACA;MAMa,MAAM,GAAG,IAAI,cAAc,CACtC,0CAA0C,EAC1C;IACE,OAAO,EAAE,MAAM,MAAM,C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AAA,EAAA,QAAA,EAAA,EAAA,EAAA,IAAA,EAAA,SAAS,cADG,MAAM,EAAA,CAAA;;2FAClB,SAAS,EAAA,UAAA,EAAA,CAAA;kBADrB,UAAU;mBAAC,EAAC,UAAU,EAAE,MAAM,EAAC;;;ACRhC;AACA;MAKa,mBAAmB,CAAA;IACtB,aAAa,GAAG,eAAe;AAEvC,IAAA,IAAI,YAAY,GAAA;QACd,OAAO,IAAI,CAAC,aAAa;IAC3B;uGALW,mBAAmB,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,UAAA,EAAA,CAAA;AAAnB,IAAA,OAAA,KAAA,GAAA,EAAA,CAAA,qBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,QAAA,EAAA,QAAA,EAAA,EAAA,EAAA,IAAA,EAAA,mBAAmB,cADP,MAAM,EAAA,CAAA;;2FAClB,mBAAmB,EAAA,UAAA,EAAA,CAAA;kBAD/B,UAAU;mBAAC,EAAC,UAAU,EAAE,MAAM,EAAC;;;ACLhC;;AAEG;;;;"}
|
|
@@ -60,10 +60,10 @@ class ListenerService {
|
|
|
60
60
|
});
|
|
61
61
|
this.listeners.clear();
|
|
62
62
|
}
|
|
63
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
64
|
-
static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "
|
|
63
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.2", ngImport: i0, type: ListenerService, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
|
|
64
|
+
static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.2.2", ngImport: i0, type: ListenerService });
|
|
65
65
|
}
|
|
66
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
66
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.2", ngImport: i0, type: ListenerService, decorators: [{
|
|
67
67
|
type: Injectable
|
|
68
68
|
}] });
|
|
69
69
|
|
|
@@ -73,7 +73,7 @@ function useCopyToClipboard(props) {
|
|
|
73
73
|
const { valueOrFn } = props;
|
|
74
74
|
const destroyRef = inject(DestroyRef);
|
|
75
75
|
const navigator = inject(NAVIGATOR);
|
|
76
|
-
const isCopied = signal(false, ...(ngDevMode ? [{ debugName: "isCopied" }] : []));
|
|
76
|
+
const isCopied = signal(false, ...(ngDevMode ? [{ debugName: "isCopied" }] : /* istanbul ignore next */ []));
|
|
77
77
|
let copyTimeout;
|
|
78
78
|
effect(() => {
|
|
79
79
|
if (isCopied()) {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"qualcomm-ui-angular-core-events.mjs","sources":["../../src/events/listener.service.ts","../../src/events/use-copy-to-clipboard.ts","../../src/events/qualcomm-ui-angular-core-events.ts"],"sourcesContent":["// Copyright (c) Qualcomm Technologies, Inc. and/or its subsidiaries.\n// SPDX-License-Identifier: BSD-3-Clause-Clear\n\nimport {DOCUMENT} from \"@angular/common\"\nimport {ElementRef, inject, Injectable, Renderer2} from \"@angular/core\"\n\nexport type ListenerTrigger = \"hover\" | \"focus\" | \"click\" | \"manual\"\n\nexport type ListenerTriggerOn = \"focus\" | \"mouse-enter\"\nexport type ListenerTriggerOff = \"blur\" | \"mouse-leave\"\nexport type ListenerTriggerToggle = \"click\"\n\nexport interface ListenerConfig {\n callbackOff?: (event: any, reason: ListenerTriggerOff) => void\n callbackOn?: (event: any, reason: ListenerTriggerOn) => void\n callbackToggle?: (event: any, reason: ListenerTriggerToggle) => void\n hostElement: ElementRef\n trigger?: ListenerTrigger | ListenerTrigger[]\n}\n\n@Injectable()\nexport class ListenerService {\n private listeners: Map<string, () => void> = new Map()\n private rendererListeners: Array<(() => void) | undefined> = []\n\n private renderer = inject(Renderer2)\n private document = inject(DOCUMENT)\n\n setDocumentListener<T extends Event>(\n eventName: string,\n callback: (event: T) => void,\n ) {\n this.setListener(this.document, eventName, callback)\n }\n\n setListener<T extends Event>(\n el: HTMLElement | Document | Window,\n eventName: string,\n callback: (event: T) => void,\n ) {\n this.rendererListeners.push(this.renderer.listen(el, eventName, callback))\n }\n\n clearDomListeners() {\n this.rendererListeners.forEach((unsub) => unsub?.())\n this.rendererListeners.fill(undefined)\n this.rendererListeners = []\n }\n\n setListeners({\n callbackOff,\n callbackOn,\n callbackToggle,\n hostElement,\n trigger,\n }: ListenerConfig): void {\n const host = hostElement.nativeElement\n const triggers = Array.isArray(trigger)\n ? trigger\n : (trigger?.split(\" \") ?? [])\n\n if (triggers.includes(\"click\")) {\n if (typeof callbackToggle === \"function\") {\n this.listeners.set(\n \"click\",\n this.renderer.listen(host, \"click\", (event) =>\n callbackToggle(event, \"click\"),\n ),\n )\n }\n }\n if (triggers.includes(\"focus\")) {\n if (typeof callbackOn === \"function\") {\n this.listeners.set(\n \"focus\",\n this.renderer.listen(host, \"focus\", (event) =>\n callbackOn(event, \"focus\"),\n ),\n )\n }\n }\n if (triggers.includes(\"click\") || triggers.includes(\"focus\")) {\n if (typeof callbackOff === \"function\") {\n this.listeners.set(\n \"blur\",\n this.renderer.listen(host, \"blur\", (event) =>\n callbackOff(event, \"blur\"),\n ),\n )\n }\n }\n if (triggers.includes(\"hover\")) {\n if (typeof callbackOn === \"function\") {\n this.listeners.set(\n \"mouseenter\",\n this.renderer.listen(host, \"mouseenter\", (event) =>\n callbackOn(event, \"mouse-enter\"),\n ),\n )\n }\n\n if (typeof callbackOff === \"function\") {\n this.listeners.set(\n \"mouseleave\",\n this.renderer.listen(host, \"mouseleave\", (event) =>\n callbackOff(event, \"mouse-leave\"),\n ),\n )\n }\n }\n }\n\n clearListeners(): void {\n this.listeners.forEach((unListen) => {\n unListen()\n })\n this.listeners.forEach((unlisten, key) => {\n // @ts-ignore\n this.listeners.set(key, null)\n })\n this.listeners.clear()\n }\n}\n","// Copyright (c) Qualcomm Technologies, Inc. and/or its subsidiaries.\n// SPDX-License-Identifier: BSD-3-Clause-Clear\n\nimport {DestroyRef, effect, inject, signal} from \"@angular/core\"\n\nimport {NAVIGATOR} from \"@qualcomm-ui/angular-core/dom\"\n\nexport interface UseCopyToClipboardProps {\n valueOrFn: (() => string) | string\n}\n\nexport interface UseCopyToClipboard {\n copyToClipboard: () => void\n isCopied: () => boolean\n}\n\nexport function useCopyToClipboard(\n props: UseCopyToClipboardProps,\n): UseCopyToClipboard {\n const {valueOrFn} = props\n const destroyRef = inject(DestroyRef)\n\n const navigator = inject(NAVIGATOR)\n\n const isCopied = signal<boolean>(false)\n let copyTimeout: ReturnType<typeof setTimeout>\n\n effect(() => {\n if (isCopied()) {\n copyTimeout = setTimeout(() => {\n isCopied.set(false)\n }, 2000)\n } else {\n if (copyTimeout !== undefined) {\n clearTimeout(copyTimeout)\n }\n }\n })\n\n destroyRef.onDestroy(() => {\n if (copyTimeout !== undefined) {\n clearTimeout(copyTimeout)\n }\n })\n\n const copyToClipboard = () => {\n if (!navigator?.clipboard) {\n console.error(\"Access to clipboard rejected!\")\n return\n }\n\n const value = typeof valueOrFn === \"function\" ? valueOrFn() : valueOrFn\n\n navigator.clipboard\n .writeText(value)\n .then(() => {\n isCopied.set(true)\n })\n .catch(() => {\n console.error(\"Failed to copy!\")\n })\n }\n\n return {\n copyToClipboard,\n isCopied: isCopied.asReadonly(),\n }\n}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;AAAA;AACA;MAoBa,eAAe,CAAA;AAClB,IAAA,SAAS,GAA4B,IAAI,GAAG,EAAE;IAC9C,iBAAiB,GAAoC,EAAE;AAEvD,IAAA,QAAQ,GAAG,MAAM,CAAC,SAAS,CAAC;AAC5B,IAAA,QAAQ,GAAG,MAAM,CAAC,QAAQ,CAAC;IAEnC,mBAAmB,CACjB,SAAiB,EACjB,QAA4B,EAAA;QAE5B,IAAI,CAAC,WAAW,CAAC,IAAI,CAAC,QAAQ,EAA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AC,SAAS,CAAC,GAAG,CAAC,GAAG,EAAE,IAAI,CAAC;AAC/B,QAAA,CAAC,CAAC;AACF,QAAA,IAAI,CAAC,SAAS,CAAC,KAAK,EAAE;IACxB;
|
|
1
|
+
{"version":3,"file":"qualcomm-ui-angular-core-events.mjs","sources":["../../src/events/listener.service.ts","../../src/events/use-copy-to-clipboard.ts","../../src/events/qualcomm-ui-angular-core-events.ts"],"sourcesContent":["// Copyright (c) Qualcomm Technologies, Inc. and/or its subsidiaries.\n// SPDX-License-Identifier: BSD-3-Clause-Clear\n\nimport {DOCUMENT} from \"@angular/common\"\nimport {ElementRef, inject, Injectable, Renderer2} from \"@angular/core\"\n\nexport type ListenerTrigger = \"hover\" | \"focus\" | \"click\" | \"manual\"\n\nexport type ListenerTriggerOn = \"focus\" | \"mouse-enter\"\nexport type ListenerTriggerOff = \"blur\" | \"mouse-leave\"\nexport type ListenerTriggerToggle = \"click\"\n\nexport interface ListenerConfig {\n callbackOff?: (event: any, reason: ListenerTriggerOff) => void\n callbackOn?: (event: any, reason: ListenerTriggerOn) => void\n callbackToggle?: (event: any, reason: ListenerTriggerToggle) => void\n hostElement: ElementRef\n trigger?: ListenerTrigger | ListenerTrigger[]\n}\n\n@Injectable()\nexport class ListenerService {\n private listeners: Map<string, () => void> = new Map()\n private rendererListeners: Array<(() => void) | undefined> = []\n\n private renderer = inject(Renderer2)\n private document = inject(DOCUMENT)\n\n setDocumentListener<T extends Event>(\n eventName: string,\n callback: (event: T) => void,\n ) {\n this.setListener(this.document, eventName, callback)\n }\n\n setListener<T extends Event>(\n el: HTMLElement | Document | Window,\n eventName: string,\n callback: (event: T) => void,\n ) {\n this.rendererListeners.push(this.renderer.listen(el, eventName, callback))\n }\n\n clearDomListeners() {\n this.rendererListeners.forEach((unsub) => unsub?.())\n this.rendererListeners.fill(undefined)\n this.rendererListeners = []\n }\n\n setListeners({\n callbackOff,\n callbackOn,\n callbackToggle,\n hostElement,\n trigger,\n }: ListenerConfig): void {\n const host = hostElement.nativeElement\n const triggers = Array.isArray(trigger)\n ? trigger\n : (trigger?.split(\" \") ?? [])\n\n if (triggers.includes(\"click\")) {\n if (typeof callbackToggle === \"function\") {\n this.listeners.set(\n \"click\",\n this.renderer.listen(host, \"click\", (event) =>\n callbackToggle(event, \"click\"),\n ),\n )\n }\n }\n if (triggers.includes(\"focus\")) {\n if (typeof callbackOn === \"function\") {\n this.listeners.set(\n \"focus\",\n this.renderer.listen(host, \"focus\", (event) =>\n callbackOn(event, \"focus\"),\n ),\n )\n }\n }\n if (triggers.includes(\"click\") || triggers.includes(\"focus\")) {\n if (typeof callbackOff === \"function\") {\n this.listeners.set(\n \"blur\",\n this.renderer.listen(host, \"blur\", (event) =>\n callbackOff(event, \"blur\"),\n ),\n )\n }\n }\n if (triggers.includes(\"hover\")) {\n if (typeof callbackOn === \"function\") {\n this.listeners.set(\n \"mouseenter\",\n this.renderer.listen(host, \"mouseenter\", (event) =>\n callbackOn(event, \"mouse-enter\"),\n ),\n )\n }\n\n if (typeof callbackOff === \"function\") {\n this.listeners.set(\n \"mouseleave\",\n this.renderer.listen(host, \"mouseleave\", (event) =>\n callbackOff(event, \"mouse-leave\"),\n ),\n )\n }\n }\n }\n\n clearListeners(): void {\n this.listeners.forEach((unListen) => {\n unListen()\n })\n this.listeners.forEach((unlisten, key) => {\n // @ts-ignore\n this.listeners.set(key, null)\n })\n this.listeners.clear()\n }\n}\n","// Copyright (c) Qualcomm Technologies, Inc. and/or its subsidiaries.\n// SPDX-License-Identifier: BSD-3-Clause-Clear\n\nimport {DestroyRef, effect, inject, signal} from \"@angular/core\"\n\nimport {NAVIGATOR} from \"@qualcomm-ui/angular-core/dom\"\n\nexport interface UseCopyToClipboardProps {\n valueOrFn: (() => string) | string\n}\n\nexport interface UseCopyToClipboard {\n copyToClipboard: () => void\n isCopied: () => boolean\n}\n\nexport function useCopyToClipboard(\n props: UseCopyToClipboardProps,\n): UseCopyToClipboard {\n const {valueOrFn} = props\n const destroyRef = inject(DestroyRef)\n\n const navigator = inject(NAVIGATOR)\n\n const isCopied = signal<boolean>(false)\n let copyTimeout: ReturnType<typeof setTimeout>\n\n effect(() => {\n if (isCopied()) {\n copyTimeout = setTimeout(() => {\n isCopied.set(false)\n }, 2000)\n } else {\n if (copyTimeout !== undefined) {\n clearTimeout(copyTimeout)\n }\n }\n })\n\n destroyRef.onDestroy(() => {\n if (copyTimeout !== undefined) {\n clearTimeout(copyTimeout)\n }\n })\n\n const copyToClipboard = () => {\n if (!navigator?.clipboard) {\n console.error(\"Access to clipboard rejected!\")\n return\n }\n\n const value = typeof valueOrFn === \"function\" ? valueOrFn() : valueOrFn\n\n navigator.clipboard\n .writeText(value)\n .then(() => {\n isCopied.set(true)\n })\n .catch(() => {\n console.error(\"Failed to copy!\")\n })\n }\n\n return {\n copyToClipboard,\n isCopied: isCopied.asReadonly(),\n }\n}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;AAAA;AACA;MAoBa,eAAe,CAAA;AAClB,IAAA,SAAS,GAA4B,IAAI,GAAG,EAAE;IAC9C,iBAAiB,GAAoC,EAAE;AAEvD,IAAA,QAAQ,GAAG,MAAM,CAAC,SAAS,CAAC;AAC5B,IAAA,QAAQ,GAAG,MAAM,CAAC,QAAQ,CAAC;IAEnC,mBAAmB,CACjB,SAAiB,EACjB,QAA4B,EAAA;QAE5B,IAAI,CAAC,WAAW,CAAC,IAAI,CAAC,QAAQ,EAAE,SAAS,EAAE,QAAQ,CAAC;IACtD;AAEA,IAAA,WAAW,CACT,EAAmC,EACnC,SAAiB,EACjB,QAA4B,EAAA;AAE5B,QAAA,IAAI,CAAC,iBAAiB,CAAC,IAAI,CAAC,IAAI,CAAC,QAAQ,CAAC,MAAM,CAAC,EAAE,EAAE,SAAS,EAAE,QAAQ,CAAC,CAAC;IAC5E;IAEA,iBAAiB,GAAA;AACf,QAAA,IAAI,CAAC,iBAAiB,CAAC,OAAO,CAAC,CAAC,KAAK,KAA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EAAE,QAAQ,CAAC,UAAU,EAAE;KAChC;AACH;;ACnEA;;AAEG;;;;"}
|
|
@@ -8,29 +8,23 @@ class HighlightDirective {
|
|
|
8
8
|
/**
|
|
9
9
|
* Whether to match whole words only
|
|
10
10
|
*/
|
|
11
|
-
exactMatch = input(undefined, ...(ngDevMode ?
|
|
12
|
-
transform: booleanAttribute,
|
|
13
|
-
}]));
|
|
11
|
+
exactMatch = input(undefined, { ...(ngDevMode ? { debugName: "exactMatch" } : /* istanbul ignore next */ {}), transform: booleanAttribute });
|
|
14
12
|
/**
|
|
15
13
|
* Whether to ignore case while matching
|
|
16
14
|
*/
|
|
17
|
-
ignoreCase = input(undefined, ...(ngDevMode ?
|
|
18
|
-
transform: booleanAttribute,
|
|
19
|
-
}]));
|
|
15
|
+
ignoreCase = input(undefined, { ...(ngDevMode ? { debugName: "ignoreCase" } : /* istanbul ignore next */ {}), transform: booleanAttribute });
|
|
20
16
|
/**
|
|
21
17
|
* Whether to match multiple instances of the query
|
|
22
18
|
*/
|
|
23
|
-
matchAll = input(undefined, ...(ngDevMode ?
|
|
24
|
-
transform: booleanAttribute,
|
|
25
|
-
}]));
|
|
19
|
+
matchAll = input(undefined, { ...(ngDevMode ? { debugName: "matchAll" } : /* istanbul ignore next */ {}), transform: booleanAttribute });
|
|
26
20
|
/**
|
|
27
21
|
* The query to highlight in the text
|
|
28
22
|
*/
|
|
29
|
-
query = input.required(...(ngDevMode ? [{ debugName: "query" }] : []));
|
|
23
|
+
query = input.required(...(ngDevMode ? [{ debugName: "query" }] : /* istanbul ignore next */ []));
|
|
30
24
|
/**
|
|
31
25
|
* The text to highlight
|
|
32
26
|
*/
|
|
33
|
-
text = input.required(...(ngDevMode ? [{ debugName: "text" }] : []));
|
|
27
|
+
text = input.required(...(ngDevMode ? [{ debugName: "text" }] : /* istanbul ignore next */ []));
|
|
34
28
|
chunks = computed(() => {
|
|
35
29
|
return highlightWord({
|
|
36
30
|
exactMatch: this.exactMatch(),
|
|
@@ -39,9 +33,9 @@ class HighlightDirective {
|
|
|
39
33
|
query: this.query() || "",
|
|
40
34
|
text: this.text() || "",
|
|
41
35
|
});
|
|
42
|
-
}, ...(ngDevMode ? [{ debugName: "chunks" }] : []));
|
|
43
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
44
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "
|
|
36
|
+
}, ...(ngDevMode ? [{ debugName: "chunks" }] : /* istanbul ignore next */ []));
|
|
37
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.2", ngImport: i0, type: HighlightDirective, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
38
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.2", type: HighlightDirective, isStandalone: true, selector: "[q-highlight]", inputs: { exactMatch: { classPropertyName: "exactMatch", publicName: "exactMatch", isSignal: true, isRequired: false, transformFunction: null }, ignoreCase: { classPropertyName: "ignoreCase", publicName: "ignoreCase", isSignal: true, isRequired: false, transformFunction: null }, matchAll: { classPropertyName: "matchAll", publicName: "matchAll", isSignal: true, isRequired: false, transformFunction: null }, query: { classPropertyName: "query", publicName: "query", isSignal: true, isRequired: true, transformFunction: null }, text: { classPropertyName: "text", publicName: "text", isSignal: true, isRequired: true, transformFunction: null } }, ngImport: i0, template: `
|
|
45
39
|
@for (chunk of chunks(); track $index) {
|
|
46
40
|
@if (chunk.match) {
|
|
47
41
|
<mark>{{ chunk.text }}</mark>
|
|
@@ -49,7 +43,7 @@ class HighlightDirective {
|
|
|
49
43
|
}
|
|
50
44
|
`, isInline: true });
|
|
51
45
|
}
|
|
52
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
46
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.2", ngImport: i0, type: HighlightDirective, decorators: [{
|
|
53
47
|
type: Component,
|
|
54
48
|
args: [{
|
|
55
49
|
selector: "[q-highlight]",
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"qualcomm-ui-angular-core-highlight.mjs","sources":["../../src/highlight/highlight.directive.ts","../../src/highlight/qualcomm-ui-angular-core-highlight.ts"],"sourcesContent":["// Copyright (c) Qualcomm Technologies, Inc. and/or its subsidiaries.\n// SPDX-License-Identifier: BSD-3-Clause-Clear\n\nimport {booleanAttribute, Component, computed, input} from \"@angular/core\"\n\nimport type {Booleanish} from \"@qualcomm-ui/utils/coercion\"\nimport {highlightWord} from \"@qualcomm-ui/utils/highlight-word\"\n\n@Component({\n selector: \"[q-highlight]\",\n standalone: true,\n // prevent prettier formatting from introducing whitespaces in the markup\n // prettier-ignore\n template: `\n @for (chunk of chunks(); track $index) {\n @if (chunk.match) {\n <mark>{{ chunk.text }}</mark>\n } @else {{{chunk.text}}}\n }\n `,\n})\nexport class HighlightDirective {\n /**\n * Whether to match whole words only\n */\n readonly exactMatch = input<boolean | undefined, Booleanish>(undefined, {\n transform: booleanAttribute,\n })\n\n /**\n * Whether to ignore case while matching\n */\n readonly ignoreCase = input<boolean | undefined, Booleanish>(undefined, {\n transform: booleanAttribute,\n })\n\n /**\n * Whether to match multiple instances of the query\n */\n readonly matchAll = input<boolean | undefined, Booleanish>(undefined, {\n transform: booleanAttribute,\n })\n\n /**\n * The query to highlight in the text\n */\n readonly query = input.required<string | string[] | undefined>()\n\n /**\n * The text to highlight\n */\n readonly text = input.required<string | null | undefined>()\n\n readonly chunks = computed(() => {\n return highlightWord({\n exactMatch: this.exactMatch(),\n ignoreCase: this.ignoreCase(),\n matchAll: this.matchAll(),\n query: this.query() || \"\",\n text: this.text() || \"\",\n })\n })\n}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;AAAA;AACA;MAoBa,kBAAkB,CAAA;AAC7B;;AAEG;IACM,UAAU,GAAG,KAAK,CAAkC,SAAS,
|
|
1
|
+
{"version":3,"file":"qualcomm-ui-angular-core-highlight.mjs","sources":["../../src/highlight/highlight.directive.ts","../../src/highlight/qualcomm-ui-angular-core-highlight.ts"],"sourcesContent":["// Copyright (c) Qualcomm Technologies, Inc. and/or its subsidiaries.\n// SPDX-License-Identifier: BSD-3-Clause-Clear\n\nimport {booleanAttribute, Component, computed, input} from \"@angular/core\"\n\nimport type {Booleanish} from \"@qualcomm-ui/utils/coercion\"\nimport {highlightWord} from \"@qualcomm-ui/utils/highlight-word\"\n\n@Component({\n selector: \"[q-highlight]\",\n standalone: true,\n // prevent prettier formatting from introducing whitespaces in the markup\n // prettier-ignore\n template: `\n @for (chunk of chunks(); track $index) {\n @if (chunk.match) {\n <mark>{{ chunk.text }}</mark>\n } @else {{{chunk.text}}}\n }\n `,\n})\nexport class HighlightDirective {\n /**\n * Whether to match whole words only\n */\n readonly exactMatch = input<boolean | undefined, Booleanish>(undefined, {\n transform: booleanAttribute,\n })\n\n /**\n * Whether to ignore case while matching\n */\n readonly ignoreCase = input<boolean | undefined, Booleanish>(undefined, {\n transform: booleanAttribute,\n })\n\n /**\n * Whether to match multiple instances of the query\n */\n readonly matchAll = input<boolean | undefined, Booleanish>(undefined, {\n transform: booleanAttribute,\n })\n\n /**\n * The query to highlight in the text\n */\n readonly query = input.required<string | string[] | undefined>()\n\n /**\n * The text to highlight\n */\n readonly text = input.required<string | null | undefined>()\n\n readonly chunks = computed(() => {\n return highlightWord({\n exactMatch: this.exactMatch(),\n ignoreCase: this.ignoreCase(),\n matchAll: this.matchAll(),\n query: this.query() || \"\",\n text: this.text() || \"\",\n })\n })\n}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;AAAA;AACA;MAoBa,kBAAkB,CAAA;AAC7B;;AAEG;IACM,UAAU,GAAG,KAAK,CAAkC,SAAS,kFACpE,SAAS,EAAE,gBAAgB,EAAA,CAC3B;AAEF;;AAEG;IACM,UAAU,GAAG,KAAK,CAAkC,SAAS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AA,EAAA,EAAA,QAAA,EAAA,EAAA,iBAAA,EAAA,UAAA,EAAA,UAAA,EAAA,UAAA,EAAA,QAAA,EAAA,IAAA,EAAA,UAAA,EAAA,KAAA,EAAA,iBAAA,EAAA,IAAA,EAAA,EAAA,KAAA,EAAA,EAAA,iBAAA,EAAA,OAAA,EAAA,UAAA,EAAA,OAAA,EAAA,QAAA,EAAA,IAAA,EAAA,UAAA,EAAA,IAAA,EAAA,iBAAA,EAAA,IAAA,EAAA,EAAA,IAAA,EAAA,EAAA,iBAAA,EAAA,MAAA,EAAA,UAAA,EAAA,MAAA,EAAA,QAAA,EAAA,IAAA,EAAA,UAAA,EAAA,IAAA,EAAA,iBAAA,EAAA,IAAA,EAAA,EAAA,EAAA,QAAA,EAAA,EAAA,EAAA,QAAA,EARnB;;;;;;AAMT,EAAA,CAAA,EAAA,QAAA,EAAA,IAAA,EAAA,CAAA;;2FAEU,kBAAkB,EAAA,UAAA,EAAA,CAAA;kBAb9B,SAAS;AAAC,YAAA,IAAA,EAAA,CAAA;AACT,oBAAA,QAAQ,EAAE,eAAe;AACzB,oBAAA,UAAU,EAAE,IAAI;;;AAGhB,oBAAA,QAAQ,EAAE;;;;;;AAMT,EAAA,CAAA;AACF,iBAAA;;;ACpBD;;AAEG;;;;"}
|
|
@@ -8,10 +8,10 @@ import { inlineNotificationMachine, createInlineNotificationApi } from '@qualcom
|
|
|
8
8
|
// Copyright (c) Qualcomm Technologies, Inc. and/or its subsidiaries.
|
|
9
9
|
// SPDX-License-Identifier: BSD-3-Clause-Clear
|
|
10
10
|
class InlineNotificationContextService extends BaseApiContextService {
|
|
11
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
12
|
-
static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "
|
|
11
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.2", ngImport: i0, type: InlineNotificationContextService, deps: null, target: i0.ɵɵFactoryTarget.Injectable });
|
|
12
|
+
static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.2.2", ngImport: i0, type: InlineNotificationContextService });
|
|
13
13
|
}
|
|
14
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
14
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.2", ngImport: i0, type: InlineNotificationContextService, decorators: [{
|
|
15
15
|
type: Injectable
|
|
16
16
|
}] });
|
|
17
17
|
const [INLINE_NOTIFICATION_CONTEXT, useInlineNotificationContext, provideInlineNotificationContext,] = createApiContext("InlineNotificationContext", InlineNotificationContextService);
|
|
@@ -26,10 +26,10 @@ class CoreInlineNotificationActionDirective {
|
|
|
26
26
|
ngOnInit() {
|
|
27
27
|
this.trackBindings();
|
|
28
28
|
}
|
|
29
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
30
|
-
static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "
|
|
29
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.2", ngImport: i0, type: CoreInlineNotificationActionDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive });
|
|
30
|
+
static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "21.2.2", type: CoreInlineNotificationActionDirective, isStandalone: true, ngImport: i0 });
|
|
31
31
|
}
|
|
32
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
32
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.2", ngImport: i0, type: CoreInlineNotificationActionDirective, decorators: [{
|
|
33
33
|
type: Directive
|
|
34
34
|
}] });
|
|
35
35
|
|
|
@@ -40,7 +40,7 @@ class CoreInlineNotificationCloseTriggerDirective {
|
|
|
40
40
|
* {@link https://www.w3schools.com/html/html_id.asp id attribute}. If
|
|
41
41
|
* omitted, a unique identifier will be generated for accessibility.
|
|
42
42
|
*/
|
|
43
|
-
id = input(...(ngDevMode ? [undefined, { debugName: "id" }] : []));
|
|
43
|
+
id = input(...(ngDevMode ? [undefined, { debugName: "id" }] : /* istanbul ignore next */ []));
|
|
44
44
|
inlineNotificationContext = useInlineNotificationContext();
|
|
45
45
|
trackBindings = useTrackBindings(() => {
|
|
46
46
|
return this.inlineNotificationContext().getCloseTriggerBindings({
|
|
@@ -49,14 +49,14 @@ class CoreInlineNotificationCloseTriggerDirective {
|
|
|
49
49
|
});
|
|
50
50
|
});
|
|
51
51
|
onDestroy = useOnDestroy();
|
|
52
|
-
hostId = computed(() => useId(this, this.id()), ...(ngDevMode ? [{ debugName: "hostId" }] : []));
|
|
52
|
+
hostId = computed(() => useId(this, this.id()), ...(ngDevMode ? [{ debugName: "hostId" }] : /* istanbul ignore next */ []));
|
|
53
53
|
ngOnInit() {
|
|
54
54
|
this.trackBindings();
|
|
55
55
|
}
|
|
56
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
57
|
-
static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "
|
|
56
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.2", ngImport: i0, type: CoreInlineNotificationCloseTriggerDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive });
|
|
57
|
+
static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "21.2.2", type: CoreInlineNotificationCloseTriggerDirective, isStandalone: true, inputs: { id: { classPropertyName: "id", publicName: "id", isSignal: true, isRequired: false, transformFunction: null } }, ngImport: i0 });
|
|
58
58
|
}
|
|
59
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
59
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.2", ngImport: i0, type: CoreInlineNotificationCloseTriggerDirective, decorators: [{
|
|
60
60
|
type: Directive
|
|
61
61
|
}], propDecorators: { id: [{ type: i0.Input, args: [{ isSignal: true, alias: "id", required: false }] }] } });
|
|
62
62
|
|
|
@@ -67,7 +67,7 @@ class CoreInlineNotificationDescriptionDirective {
|
|
|
67
67
|
* {@link https://www.w3schools.com/html/html_id.asp id attribute}. If
|
|
68
68
|
* omitted, a unique identifier will be generated for accessibility.
|
|
69
69
|
*/
|
|
70
|
-
id = input(...(ngDevMode ? [undefined, { debugName: "id" }] : []));
|
|
70
|
+
id = input(...(ngDevMode ? [undefined, { debugName: "id" }] : /* istanbul ignore next */ []));
|
|
71
71
|
inlineNotificationContext = useInlineNotificationContext();
|
|
72
72
|
trackBindings = useTrackBindings(() => {
|
|
73
73
|
return this.inlineNotificationContext().getDescriptionBindings({
|
|
@@ -76,14 +76,14 @@ class CoreInlineNotificationDescriptionDirective {
|
|
|
76
76
|
});
|
|
77
77
|
});
|
|
78
78
|
onDestroy = useOnDestroy();
|
|
79
|
-
hostId = computed(() => useId(this, this.id()), ...(ngDevMode ? [{ debugName: "hostId" }] : []));
|
|
79
|
+
hostId = computed(() => useId(this, this.id()), ...(ngDevMode ? [{ debugName: "hostId" }] : /* istanbul ignore next */ []));
|
|
80
80
|
ngOnInit() {
|
|
81
81
|
this.trackBindings();
|
|
82
82
|
}
|
|
83
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
84
|
-
static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "
|
|
83
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.2", ngImport: i0, type: CoreInlineNotificationDescriptionDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive });
|
|
84
|
+
static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "21.2.2", type: CoreInlineNotificationDescriptionDirective, isStandalone: true, inputs: { id: { classPropertyName: "id", publicName: "id", isSignal: true, isRequired: false, transformFunction: null } }, ngImport: i0 });
|
|
85
85
|
}
|
|
86
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
86
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.2", ngImport: i0, type: CoreInlineNotificationDescriptionDirective, decorators: [{
|
|
87
87
|
type: Directive
|
|
88
88
|
}], propDecorators: { id: [{ type: i0.Input, args: [{ isSignal: true, alias: "id", required: false }] }] } });
|
|
89
89
|
|
|
@@ -97,10 +97,10 @@ class CoreInlineNotificationIconDirective {
|
|
|
97
97
|
ngOnInit() {
|
|
98
98
|
this.trackBindings();
|
|
99
99
|
}
|
|
100
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
101
|
-
static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "
|
|
100
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.2", ngImport: i0, type: CoreInlineNotificationIconDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive });
|
|
101
|
+
static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "21.2.2", type: CoreInlineNotificationIconDirective, isStandalone: true, ngImport: i0 });
|
|
102
102
|
}
|
|
103
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
103
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.2", ngImport: i0, type: CoreInlineNotificationIconDirective, decorators: [{
|
|
104
104
|
type: Directive
|
|
105
105
|
}] });
|
|
106
106
|
|
|
@@ -111,7 +111,7 @@ class CoreInlineNotificationLabelDirective {
|
|
|
111
111
|
* {@link https://www.w3schools.com/html/html_id.asp id attribute}. If
|
|
112
112
|
* omitted, a unique identifier will be generated for accessibility.
|
|
113
113
|
*/
|
|
114
|
-
id = input(...(ngDevMode ? [undefined, { debugName: "id" }] : []));
|
|
114
|
+
id = input(...(ngDevMode ? [undefined, { debugName: "id" }] : /* istanbul ignore next */ []));
|
|
115
115
|
inlineNotificationContext = useInlineNotificationContext();
|
|
116
116
|
trackBindings = useTrackBindings(() => {
|
|
117
117
|
return this.inlineNotificationContext().getLabelBindings({
|
|
@@ -120,14 +120,14 @@ class CoreInlineNotificationLabelDirective {
|
|
|
120
120
|
});
|
|
121
121
|
});
|
|
122
122
|
onDestroy = useOnDestroy();
|
|
123
|
-
hostId = computed(() => useId(this, this.id()), ...(ngDevMode ? [{ debugName: "hostId" }] : []));
|
|
123
|
+
hostId = computed(() => useId(this, this.id()), ...(ngDevMode ? [{ debugName: "hostId" }] : /* istanbul ignore next */ []));
|
|
124
124
|
ngOnInit() {
|
|
125
125
|
this.trackBindings();
|
|
126
126
|
}
|
|
127
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
128
|
-
static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "
|
|
127
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.2", ngImport: i0, type: CoreInlineNotificationLabelDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive });
|
|
128
|
+
static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "21.2.2", type: CoreInlineNotificationLabelDirective, isStandalone: true, inputs: { id: { classPropertyName: "id", publicName: "id", isSignal: true, isRequired: false, transformFunction: null } }, ngImport: i0 });
|
|
129
129
|
}
|
|
130
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
130
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.2", ngImport: i0, type: CoreInlineNotificationLabelDirective, decorators: [{
|
|
131
131
|
type: Directive
|
|
132
132
|
}], propDecorators: { id: [{ type: i0.Input, args: [{ isSignal: true, alias: "id", required: false }] }] } });
|
|
133
133
|
|
|
@@ -139,17 +139,17 @@ class CoreInlineNotificationRootDirective {
|
|
|
139
139
|
*
|
|
140
140
|
* @default "ltr"
|
|
141
141
|
*/
|
|
142
|
-
dir = input(undefined, ...(ngDevMode ? [{ debugName: "dir" }] : []));
|
|
142
|
+
dir = input(undefined, ...(ngDevMode ? [{ debugName: "dir" }] : /* istanbul ignore next */ []));
|
|
143
143
|
/**
|
|
144
144
|
* A root node to correctly resolve the Document in custom environments. i.e.,
|
|
145
145
|
* Iframes, Electron.
|
|
146
146
|
*/
|
|
147
|
-
getRootNode = input(...(ngDevMode ? [undefined, { debugName: "getRootNode" }] : []));
|
|
147
|
+
getRootNode = input(...(ngDevMode ? [undefined, { debugName: "getRootNode" }] : /* istanbul ignore next */ []));
|
|
148
148
|
/**
|
|
149
149
|
* {@link https://www.w3schools.com/html/html_id.asp id attribute}. If
|
|
150
150
|
* omitted, a unique identifier will be generated for accessibility.
|
|
151
151
|
*/
|
|
152
|
-
id = input(...(ngDevMode ? [undefined, { debugName: "id" }] : []));
|
|
152
|
+
id = input(...(ngDevMode ? [undefined, { debugName: "id" }] : /* istanbul ignore next */ []));
|
|
153
153
|
/**
|
|
154
154
|
* The WAI-ARIA {@link https://developer.mozilla.org/en-US/docs/Web/Accessibility/ARIA/Reference/Roles role} of the notification.
|
|
155
155
|
* @option `'alert'`: Use this role when the notification is an alert that requires the user's immediate attention, like for errors or urgent information.
|
|
@@ -157,7 +157,7 @@ class CoreInlineNotificationRootDirective {
|
|
|
157
157
|
*
|
|
158
158
|
* @default 'status'
|
|
159
159
|
*/
|
|
160
|
-
role = input(...(ngDevMode ? [undefined, { debugName: "role" }] : []));
|
|
160
|
+
role = input(...(ngDevMode ? [undefined, { debugName: "role" }] : /* istanbul ignore next */ []));
|
|
161
161
|
/**
|
|
162
162
|
* Function invoked when the notification is dismissed
|
|
163
163
|
*/
|
|
@@ -173,7 +173,7 @@ class CoreInlineNotificationRootDirective {
|
|
|
173
173
|
injector = inject(Injector);
|
|
174
174
|
isMounted = useIsMounted();
|
|
175
175
|
document = inject(DOCUMENT);
|
|
176
|
-
hostId = computed(() => useId(this, this.id()), ...(ngDevMode ? [{ debugName: "hostId" }] : []));
|
|
176
|
+
hostId = computed(() => useId(this, this.id()), ...(ngDevMode ? [{ debugName: "hostId" }] : /* istanbul ignore next */ []));
|
|
177
177
|
ngOnInit() {
|
|
178
178
|
const machine = useMachine(inlineNotificationMachine, computed(() => ({
|
|
179
179
|
dir: this.dir(),
|
|
@@ -188,10 +188,10 @@ class CoreInlineNotificationRootDirective {
|
|
|
188
188
|
this.inlineNotificationService.init(computed(() => createInlineNotificationApi(machine, normalizeProps)));
|
|
189
189
|
this.trackBindings();
|
|
190
190
|
}
|
|
191
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
192
|
-
static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "
|
|
191
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.2", ngImport: i0, type: CoreInlineNotificationRootDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive });
|
|
192
|
+
static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "21.2.2", type: CoreInlineNotificationRootDirective, isStandalone: true, inputs: { dir: { classPropertyName: "dir", publicName: "dir", isSignal: true, isRequired: false, transformFunction: null }, getRootNode: { classPropertyName: "getRootNode", publicName: "getRootNode", isSignal: true, isRequired: false, transformFunction: null }, id: { classPropertyName: "id", publicName: "id", isSignal: true, isRequired: false, transformFunction: null }, role: { classPropertyName: "role", publicName: "role", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { dismissed: "dismissed" }, ngImport: i0 });
|
|
193
193
|
}
|
|
194
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
194
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.2", ngImport: i0, type: CoreInlineNotificationRootDirective, decorators: [{
|
|
195
195
|
type: Directive
|
|
196
196
|
}], propDecorators: { dir: [{ type: i0.Input, args: [{ isSignal: true, alias: "dir", required: false }] }], getRootNode: [{ type: i0.Input, args: [{ isSignal: true, alias: "getRootNode", required: false }] }], id: [{ type: i0.Input, args: [{ isSignal: true, alias: "id", required: false }] }], role: [{ type: i0.Input, args: [{ isSignal: true, alias: "role", required: false }] }], dismissed: [{ type: i0.Output, args: ["dismissed"] }] } });
|
|
197
197
|
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"qualcomm-ui-angular-core-inline-notification.mjs","sources":["../../src/inline-notification/inline-notification-context.service.ts","../../src/inline-notification/core-inline-notification-action.directive.ts","../../src/inline-notification/core-inline-notification-close-trigger.directive.ts","../../src/inline-notification/core-inline-notification-description.directive.ts","../../src/inline-notification/core-inline-notification-icon.directive.ts","../../src/inline-notification/core-inline-notification-label.directive.ts","../../src/inline-notification/core-inline-notification-root.directive.ts","../../src/inline-notification/qualcomm-ui-angular-core-inline-notification.ts"],"sourcesContent":["// Copyright (c) Qualcomm Technologies, Inc. and/or its subsidiaries.\n// SPDX-License-Identifier: BSD-3-Clause-Clear\n\nimport {Injectable} from \"@angular/core\"\n\nimport {\n type ApiContext,\n BaseApiContextService,\n createApiContext,\n} from \"@qualcomm-ui/angular-core/machine\"\nimport type {InlineNotificationApi} from \"@qualcomm-ui/core/inline-notification\"\n\n@Injectable()\nexport class InlineNotificationContextService extends BaseApiContextService<InlineNotificationApi> {}\n\nexport const [\n INLINE_NOTIFICATION_CONTEXT,\n useInlineNotificationContext,\n provideInlineNotificationContext,\n]: ApiContext<InlineNotificationApi> = createApiContext<InlineNotificationApi>(\n \"InlineNotificationContext\",\n InlineNotificationContextService,\n)\n","// Copyright (c) Qualcomm Technologies, Inc. and/or its subsidiaries.\n// SPDX-License-Identifier: BSD-3-Clause-Clear\n\nimport {Directive, type OnInit} from \"@angular/core\"\n\nimport {useTrackBindings} from \"@qualcomm-ui/angular-core/machine\"\n\nimport {useInlineNotificationContext} from \"./inline-notification-context.service\"\n\n@Directive()\nexport class CoreInlineNotificationActionDirective implements OnInit {\n protected readonly inlineNotificationContext = useInlineNotificationContext()\n\n protected readonly trackBindings = useTrackBindings(() => {\n return this.inlineNotificationContext().getActionBindings()\n })\n\n ngOnInit() {\n this.trackBindings()\n }\n}\n","// Copyright (c) Qualcomm Technologies, Inc. and/or its subsidiaries.\n// SPDX-License-Identifier: BSD-3-Clause-Clear\n\nimport {computed, Directive, input, type OnInit} from \"@angular/core\"\n\nimport {useId, useOnDestroy} from \"@qualcomm-ui/angular-core/common\"\nimport {useTrackBindings} from \"@qualcomm-ui/angular-core/machine\"\n\nimport {useInlineNotificationContext} from \"./inline-notification-context.service\"\n\n@Directive()\nexport class CoreInlineNotificationCloseTriggerDirective implements OnInit {\n /**\n * {@link https://www.w3schools.com/html/html_id.asp id attribute}. If\n * omitted, a unique identifier will be generated for accessibility.\n */\n readonly id = input<string>()\n\n protected readonly inlineNotificationContext = useInlineNotificationContext()\n\n protected readonly trackBindings = useTrackBindings(() => {\n return this.inlineNotificationContext().getCloseTriggerBindings({\n id: this.hostId(),\n onDestroy: this.onDestroy,\n })\n })\n\n protected readonly onDestroy = useOnDestroy()\n\n private readonly hostId = computed(() => useId(this, this.id()))\n\n ngOnInit() {\n this.trackBindings()\n }\n}\n","// Copyright (c) Qualcomm Technologies, Inc. and/or its subsidiaries.\n// SPDX-License-Identifier: BSD-3-Clause-Clear\n\nimport {computed, Directive, input, type OnInit} from \"@angular/core\"\n\nimport {useId, useOnDestroy} from \"@qualcomm-ui/angular-core/common\"\nimport {useTrackBindings} from \"@qualcomm-ui/angular-core/machine\"\n\nimport {useInlineNotificationContext} from \"./inline-notification-context.service\"\n\n@Directive()\nexport class CoreInlineNotificationDescriptionDirective implements OnInit {\n /**\n * {@link https://www.w3schools.com/html/html_id.asp id attribute}. If\n * omitted, a unique identifier will be generated for accessibility.\n */\n readonly id = input<string>()\n\n protected readonly inlineNotificationContext = useInlineNotificationContext()\n\n protected readonly trackBindings = useTrackBindings(() => {\n return this.inlineNotificationContext().getDescriptionBindings({\n id: this.hostId(),\n onDestroy: this.onDestroy,\n })\n })\n\n protected readonly onDestroy = useOnDestroy()\n\n private readonly hostId = computed(() => useId(this, this.id()))\n\n ngOnInit() {\n this.trackBindings()\n }\n}\n","// Copyright (c) Qualcomm Technologies, Inc. and/or its subsidiaries.\n// SPDX-License-Identifier: BSD-3-Clause-Clear\n\nimport {Directive, type OnInit} from \"@angular/core\"\n\nimport {useTrackBindings} from \"@qualcomm-ui/angular-core/machine\"\n\nimport {useInlineNotificationContext} from \"./inline-notification-context.service\"\n\n@Directive()\nexport class CoreInlineNotificationIconDirective implements OnInit {\n protected readonly inlineNotificationContext = useInlineNotificationContext()\n\n protected readonly trackBindings = useTrackBindings(() => {\n return this.inlineNotificationContext().getIconBindings()\n })\n\n ngOnInit() {\n this.trackBindings()\n }\n}\n","// Copyright (c) Qualcomm Technologies, Inc. and/or its subsidiaries.\n// SPDX-License-Identifier: BSD-3-Clause-Clear\n\nimport {computed, Directive, input, type OnInit} from \"@angular/core\"\n\nimport {useId, useOnDestroy} from \"@qualcomm-ui/angular-core/common\"\nimport {useTrackBindings} from \"@qualcomm-ui/angular-core/machine\"\n\nimport {useInlineNotificationContext} from \"./inline-notification-context.service\"\n\n@Directive()\nexport class CoreInlineNotificationLabelDirective implements OnInit {\n /**\n * {@link https://www.w3schools.com/html/html_id.asp id attribute}. If\n * omitted, a unique identifier will be generated for accessibility.\n */\n readonly id = input<string>()\n\n protected readonly inlineNotificationContext = useInlineNotificationContext()\n\n protected readonly trackBindings = useTrackBindings(() => {\n return this.inlineNotificationContext().getLabelBindings({\n id: this.hostId(),\n onDestroy: this.onDestroy,\n })\n })\n\n protected readonly onDestroy = useOnDestroy()\n\n private readonly hostId = computed(() => useId(this, this.id()))\n\n ngOnInit() {\n this.trackBindings()\n }\n}\n","// Copyright (c) Qualcomm Technologies, Inc. and/or its subsidiaries.\n// SPDX-License-Identifier: BSD-3-Clause-Clear\n\nimport {DOCUMENT} from \"@angular/common\"\nimport {\n computed,\n Directive,\n inject,\n Injector,\n input,\n type OnInit,\n output,\n} from \"@angular/core\"\n\nimport {\n useId,\n useIsMounted,\n useOnDestroy,\n} from \"@qualcomm-ui/angular-core/common\"\nimport {\n normalizeProps,\n useMachine,\n useTrackBindings,\n} from \"@qualcomm-ui/angular-core/machine\"\nimport type {SignalifyInput} from \"@qualcomm-ui/angular-core/signals\"\nimport {\n createInlineNotificationApi,\n type InlineNotificationApiProps,\n inlineNotificationMachine,\n} from \"@qualcomm-ui/core/inline-notification\"\nimport type {Direction} from \"@qualcomm-ui/utils/direction\"\nimport type {Explicit} from \"@qualcomm-ui/utils/guard\"\n\nimport {InlineNotificationContextService} from \"./inline-notification-context.service\"\n\n@Directive()\nexport class CoreInlineNotificationRootDirective\n implements SignalifyInput<InlineNotificationApiProps>, OnInit\n{\n /**\n * The document's text/writing direction.\n *\n * @default \"ltr\"\n */\n readonly dir = input<Direction | undefined>(undefined)\n\n /**\n * A root node to correctly resolve the Document in custom environments. i.e.,\n * Iframes, Electron.\n */\n readonly getRootNode = input<\n (() => ShadowRoot | Document | Node) | undefined\n >()\n\n /**\n * {@link https://www.w3schools.com/html/html_id.asp id attribute}. If\n * omitted, a unique identifier will be generated for accessibility.\n */\n readonly id = input<string>()\n\n /**\n * The WAI-ARIA {@link https://developer.mozilla.org/en-US/docs/Web/Accessibility/ARIA/Reference/Roles role} of the notification.\n * @option `'alert'`: Use this role when the notification is an alert that requires the user's immediate attention, like for errors or urgent information.\n * @option `'status'`: Use this role when the notification is a status message that doesn't require the user's immediate attention, like for success or informational messages.\n *\n * @default 'status'\n */\n readonly role = input<\"alert\" | \"status\">()\n\n /**\n * Function invoked when the notification is dismissed\n */\n readonly dismissed = output<void>()\n\n protected readonly inlineNotificationService = inject(\n InlineNotificationContextService,\n )\n\n protected readonly trackBindings = useTrackBindings(() => {\n return this.inlineNotificationService.context().getRootBindings({\n id: this.hostId(),\n onDestroy: this.onDestroy,\n })\n })\n\n protected readonly onDestroy = useOnDestroy()\n\n protected readonly injector = inject(Injector)\n\n protected readonly isMounted = useIsMounted()\n\n private document = inject(DOCUMENT)\n\n private readonly hostId = computed(() => useId(this, this.id()))\n\n ngOnInit() {\n const machine = useMachine(\n inlineNotificationMachine,\n computed<Explicit<InlineNotificationApiProps>>(() => ({\n dir: this.dir(),\n getRootNode: this.getRootNode() || (() => this.document),\n onDismiss: () => {\n if (this.isMounted()) {\n this.dismissed.emit()\n }\n },\n role: this.role(),\n })),\n this.injector,\n )\n\n this.inlineNotificationService.init(\n computed(() => createInlineNotificationApi(machine, normalizeProps)),\n )\n\n this.trackBindings()\n }\n}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;;;AAAA;AACA;AAYM,MAAO,gCAAiC,SAAQ,qBAA4C,CAAA;wGAArF,gCAAgC,EAAA,IAAA,EAAA,IAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,UAAA,EAAA,CAAA;4GAAhC,gCAAgC,EAAA,CAAA;;4FAAhC,gCAAgC,EAAA,UAAA,EAAA,CAAA;kBAD5C;;AAGM,MAAM,CACX,2BAA2B,EAC3B,4BAA4B,EAC5B,gCAAgC,EACjC,GAAsC,gBAAgB,CACrD,2BAA2B,EAC3B,gCAAgC;;ACrBlC;AACA;MASa,qCAAqC,CAAA;IAC7B,yBAAyB,GAAG,4BAA4B,EAAE;AAE1D,IAAA,aAAa,GAAG,gBAAgB,CAAC,MAAK;AACvD,QAAA,OAAO,IAAI,CAAC,yBAAyB,EAAE,CAAC,iBAAiB,EAAE;AAC7D,IAAA,CAAC,CAAC;IAEF,QAAQ,GAAA;QACN,IAAI,CAAC,aAAa,EAAE;IACtB;wGATW,qCAAqC,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,SAAA,EAAA,CAAA;4FAArC,qCAAqC,EAAA,YAAA,EAAA,IAAA,EAAA,QAAA,EAAA,EAAA,EAAA,CAAA;;4FAArC,qCAAqC,EAA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,EAAA,WAAA,EAAA,EAAA,QAAA,EAAA,EAAA,EAAA,CAAA;;4FAAnC,mCAAmC,EAAA,UAAA,EAAA,CAAA;kBAD/C;;;ACnCD;;AAEG;;;;"}
|
|
1
|
+
{"version":3,"file":"qualcomm-ui-angular-core-inline-notification.mjs","sources":["../../src/inline-notification/inline-notification-context.service.ts","../../src/inline-notification/core-inline-notification-action.directive.ts","../../src/inline-notification/core-inline-notification-close-trigger.directive.ts","../../src/inline-notification/core-inline-notification-description.directive.ts","../../src/inline-notification/core-inline-notification-icon.directive.ts","../../src/inline-notification/core-inline-notification-label.directive.ts","../../src/inline-notification/core-inline-notification-root.directive.ts","../../src/inline-notification/qualcomm-ui-angular-core-inline-notification.ts"],"sourcesContent":["// Copyright (c) Qualcomm Technologies, Inc. and/or its subsidiaries.\n// SPDX-License-Identifier: BSD-3-Clause-Clear\n\nimport {Injectable} from \"@angular/core\"\n\nimport {\n type ApiContext,\n BaseApiContextService,\n createApiContext,\n} from \"@qualcomm-ui/angular-core/machine\"\nimport type {InlineNotificationApi} from \"@qualcomm-ui/core/inline-notification\"\n\n@Injectable()\nexport class InlineNotificationContextService extends BaseApiContextService<InlineNotificationApi> {}\n\nexport const [\n INLINE_NOTIFICATION_CONTEXT,\n useInlineNotificationContext,\n provideInlineNotificationContext,\n]: ApiContext<InlineNotificationApi> = createApiContext<InlineNotificationApi>(\n \"InlineNotificationContext\",\n InlineNotificationContextService,\n)\n","// Copyright (c) Qualcomm Technologies, Inc. and/or its subsidiaries.\n// SPDX-License-Identifier: BSD-3-Clause-Clear\n\nimport {Directive, type OnInit} from \"@angular/core\"\n\nimport {useTrackBindings} from \"@qualcomm-ui/angular-core/machine\"\n\nimport {useInlineNotificationContext} from \"./inline-notification-context.service\"\n\n@Directive()\nexport class CoreInlineNotificationActionDirective implements OnInit {\n protected readonly inlineNotificationContext = useInlineNotificationContext()\n\n protected readonly trackBindings = useTrackBindings(() => {\n return this.inlineNotificationContext().getActionBindings()\n })\n\n ngOnInit() {\n this.trackBindings()\n }\n}\n","// Copyright (c) Qualcomm Technologies, Inc. and/or its subsidiaries.\n// SPDX-License-Identifier: BSD-3-Clause-Clear\n\nimport {computed, Directive, input, type OnInit} from \"@angular/core\"\n\nimport {useId, useOnDestroy} from \"@qualcomm-ui/angular-core/common\"\nimport {useTrackBindings} from \"@qualcomm-ui/angular-core/machine\"\n\nimport {useInlineNotificationContext} from \"./inline-notification-context.service\"\n\n@Directive()\nexport class CoreInlineNotificationCloseTriggerDirective implements OnInit {\n /**\n * {@link https://www.w3schools.com/html/html_id.asp id attribute}. If\n * omitted, a unique identifier will be generated for accessibility.\n */\n readonly id = input<string>()\n\n protected readonly inlineNotificationContext = useInlineNotificationContext()\n\n protected readonly trackBindings = useTrackBindings(() => {\n return this.inlineNotificationContext().getCloseTriggerBindings({\n id: this.hostId(),\n onDestroy: this.onDestroy,\n })\n })\n\n protected readonly onDestroy = useOnDestroy()\n\n private readonly hostId = computed(() => useId(this, this.id()))\n\n ngOnInit() {\n this.trackBindings()\n }\n}\n","// Copyright (c) Qualcomm Technologies, Inc. and/or its subsidiaries.\n// SPDX-License-Identifier: BSD-3-Clause-Clear\n\nimport {computed, Directive, input, type OnInit} from \"@angular/core\"\n\nimport {useId, useOnDestroy} from \"@qualcomm-ui/angular-core/common\"\nimport {useTrackBindings} from \"@qualcomm-ui/angular-core/machine\"\n\nimport {useInlineNotificationContext} from \"./inline-notification-context.service\"\n\n@Directive()\nexport class CoreInlineNotificationDescriptionDirective implements OnInit {\n /**\n * {@link https://www.w3schools.com/html/html_id.asp id attribute}. If\n * omitted, a unique identifier will be generated for accessibility.\n */\n readonly id = input<string>()\n\n protected readonly inlineNotificationContext = useInlineNotificationContext()\n\n protected readonly trackBindings = useTrackBindings(() => {\n return this.inlineNotificationContext().getDescriptionBindings({\n id: this.hostId(),\n onDestroy: this.onDestroy,\n })\n })\n\n protected readonly onDestroy = useOnDestroy()\n\n private readonly hostId = computed(() => useId(this, this.id()))\n\n ngOnInit() {\n this.trackBindings()\n }\n}\n","// Copyright (c) Qualcomm Technologies, Inc. and/or its subsidiaries.\n// SPDX-License-Identifier: BSD-3-Clause-Clear\n\nimport {Directive, type OnInit} from \"@angular/core\"\n\nimport {useTrackBindings} from \"@qualcomm-ui/angular-core/machine\"\n\nimport {useInlineNotificationContext} from \"./inline-notification-context.service\"\n\n@Directive()\nexport class CoreInlineNotificationIconDirective implements OnInit {\n protected readonly inlineNotificationContext = useInlineNotificationContext()\n\n protected readonly trackBindings = useTrackBindings(() => {\n return this.inlineNotificationContext().getIconBindings()\n })\n\n ngOnInit() {\n this.trackBindings()\n }\n}\n","// Copyright (c) Qualcomm Technologies, Inc. and/or its subsidiaries.\n// SPDX-License-Identifier: BSD-3-Clause-Clear\n\nimport {computed, Directive, input, type OnInit} from \"@angular/core\"\n\nimport {useId, useOnDestroy} from \"@qualcomm-ui/angular-core/common\"\nimport {useTrackBindings} from \"@qualcomm-ui/angular-core/machine\"\n\nimport {useInlineNotificationContext} from \"./inline-notification-context.service\"\n\n@Directive()\nexport class CoreInlineNotificationLabelDirective implements OnInit {\n /**\n * {@link https://www.w3schools.com/html/html_id.asp id attribute}. If\n * omitted, a unique identifier will be generated for accessibility.\n */\n readonly id = input<string>()\n\n protected readonly inlineNotificationContext = useInlineNotificationContext()\n\n protected readonly trackBindings = useTrackBindings(() => {\n return this.inlineNotificationContext().getLabelBindings({\n id: this.hostId(),\n onDestroy: this.onDestroy,\n })\n })\n\n protected readonly onDestroy = useOnDestroy()\n\n private readonly hostId = computed(() => useId(this, this.id()))\n\n ngOnInit() {\n this.trackBindings()\n }\n}\n","// Copyright (c) Qualcomm Technologies, Inc. and/or its subsidiaries.\n// SPDX-License-Identifier: BSD-3-Clause-Clear\n\nimport {DOCUMENT} from \"@angular/common\"\nimport {\n computed,\n Directive,\n inject,\n Injector,\n input,\n type OnInit,\n output,\n} from \"@angular/core\"\n\nimport {\n useId,\n useIsMounted,\n useOnDestroy,\n} from \"@qualcomm-ui/angular-core/common\"\nimport {\n normalizeProps,\n useMachine,\n useTrackBindings,\n} from \"@qualcomm-ui/angular-core/machine\"\nimport type {SignalifyInput} from \"@qualcomm-ui/angular-core/signals\"\nimport {\n createInlineNotificationApi,\n type InlineNotificationApiProps,\n inlineNotificationMachine,\n} from \"@qualcomm-ui/core/inline-notification\"\nimport type {Direction} from \"@qualcomm-ui/utils/direction\"\nimport type {Explicit} from \"@qualcomm-ui/utils/guard\"\n\nimport {InlineNotificationContextService} from \"./inline-notification-context.service\"\n\n@Directive()\nexport class CoreInlineNotificationRootDirective\n implements SignalifyInput<InlineNotificationApiProps>, OnInit\n{\n /**\n * The document's text/writing direction.\n *\n * @default \"ltr\"\n */\n readonly dir = input<Direction | undefined>(undefined)\n\n /**\n * A root node to correctly resolve the Document in custom environments. i.e.,\n * Iframes, Electron.\n */\n readonly getRootNode = input<\n (() => ShadowRoot | Document | Node) | undefined\n >()\n\n /**\n * {@link https://www.w3schools.com/html/html_id.asp id attribute}. If\n * omitted, a unique identifier will be generated for accessibility.\n */\n readonly id = input<string>()\n\n /**\n * The WAI-ARIA {@link https://developer.mozilla.org/en-US/docs/Web/Accessibility/ARIA/Reference/Roles role} of the notification.\n * @option `'alert'`: Use this role when the notification is an alert that requires the user's immediate attention, like for errors or urgent information.\n * @option `'status'`: Use this role when the notification is a status message that doesn't require the user's immediate attention, like for success or informational messages.\n *\n * @default 'status'\n */\n readonly role = input<\"alert\" | \"status\">()\n\n /**\n * Function invoked when the notification is dismissed\n */\n readonly dismissed = output<void>()\n\n protected readonly inlineNotificationService = inject(\n InlineNotificationContextService,\n )\n\n protected readonly trackBindings = useTrackBindings(() => {\n return this.inlineNotificationService.context().getRootBindings({\n id: this.hostId(),\n onDestroy: this.onDestroy,\n })\n })\n\n protected readonly onDestroy = useOnDestroy()\n\n protected readonly injector = inject(Injector)\n\n protected readonly isMounted = useIsMounted()\n\n private document = inject(DOCUMENT)\n\n private readonly hostId = computed(() => useId(this, this.id()))\n\n ngOnInit() {\n const machine = useMachine(\n inlineNotificationMachine,\n computed<Explicit<InlineNotificationApiProps>>(() => ({\n dir: this.dir(),\n getRootNode: this.getRootNode() || (() => this.document),\n onDismiss: () => {\n if (this.isMounted()) {\n this.dismissed.emit()\n }\n },\n role: this.role(),\n })),\n this.injector,\n )\n\n this.inlineNotificationService.init(\n computed(() => createInlineNotificationApi(machine, normalizeProps)),\n )\n\n this.trackBindings()\n }\n}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;;;AAAA;AACA;AAYM,MAAO,gCAAiC,SAAQ,qBAA4C,CAAA;uGAArF,gCAAgC,EAAA,IAAA,EAAA,IAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,UAAA,EAAA,CAAA;2GAAhC,gCAAgC,EAAA,CAAA;;2FAAhC,gCAAgC,EAAA,UAAA,EAAA,CAAA;kBAD5C;;AAGM,MAAM,CACX,2BAA2B,EAC3B,4BAA4B,EAC5B,gCAAgC,EACjC,GAAsC,gBAAgB,CACrD,2BAA2B,EAC3B,gCAAgC;;ACrBlC;AACA;MASa,qCAAqC,CAAA;IAC7B,yBAAyB,GAAG,4BAA4B,EAAE;AAE1D,IAAA,aAAa,GAAG,gBAAgB,CAAC,MAAK;AACvD,QAAA,OAAO,IAAI,CAAC,yBAAyB,EAAE,CAAC,iBAAiB,EAAE;AAC7D,IAAA,CAAC,CAAC;IAEF,QAAQ,GAAA;QACN,IAAI,CAAC,aAAa,EAAE;IACtB;uGATW,qCAAqC,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,SAAA,EAAA,CAAA;2FAArC,qCAAqC,EAAA,YAAA,EAAA,IAAA,EAAA,QAAA,EAAA,EAAA,EAAA,CAAA;;2FAArC,qCAAqC,EAAA,UAAA,EAAA,CAAA;kBADjD;;;ACTD;AACA;MAUa,2CAA2C,CAAA;AACtD;;;AAGG;IACM,EAAE,GAAG,KAAK,CAAA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