chrv-components 1.12.127 → 1.12.128
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.
|
Binary file
|
|
@@ -4020,7 +4020,7 @@ class ChrPopoverDirective {
|
|
|
4020
4020
|
this.viewContainerRef = inject(ViewContainerRef);
|
|
4021
4021
|
this.hostElement = computed(() => this.hostElementRef.nativeElement, /* @ts-ignore */
|
|
4022
4022
|
...(ngDevMode ? [{ debugName: "hostElement" }] : /* istanbul ignore next */ []));
|
|
4023
|
-
this.isInsideSubject = new
|
|
4023
|
+
this.isInsideSubject = new BehaviorSubject(false);
|
|
4024
4024
|
this.destroyRef = inject(DestroyRef);
|
|
4025
4025
|
// private readonly isInsideHost = signal(false);
|
|
4026
4026
|
// private readonly isInsideTarget = signal(false);
|
|
@@ -4072,9 +4072,10 @@ class ChrPopoverDirective {
|
|
|
4072
4072
|
};
|
|
4073
4073
|
this.setupHostListeners = () => {
|
|
4074
4074
|
this.renderer.listen(this.hostElement(), 'mouseenter', (event) => {
|
|
4075
|
-
// this.isInsideHost.set(true);
|
|
4076
|
-
this.shopPopover();
|
|
4077
4075
|
this.isInsideSubject.next(true);
|
|
4076
|
+
if (!this.isOpen()) {
|
|
4077
|
+
this.showPopover();
|
|
4078
|
+
}
|
|
4078
4079
|
});
|
|
4079
4080
|
this.renderer.listen(this.hostElement(), 'mouseleave', (event) => {
|
|
4080
4081
|
// this.isInsideHost.set(false);
|
|
@@ -4089,7 +4090,7 @@ class ChrPopoverDirective {
|
|
|
4089
4090
|
this.setupTargetListeners = () => {
|
|
4090
4091
|
this.renderer.listen(this.targetElement(), 'mouseenter', (event) => {
|
|
4091
4092
|
// this.isInsideTarget.set(true);
|
|
4092
|
-
this.shopPopover();
|
|
4093
|
+
// this.shopPopover();
|
|
4093
4094
|
this.isInsideSubject.next(true);
|
|
4094
4095
|
});
|
|
4095
4096
|
this.renderer.listen(this.targetElement(), 'mouseleave', (event) => {
|
|
@@ -4101,7 +4102,7 @@ class ChrPopoverDirective {
|
|
|
4101
4102
|
// }, 100);
|
|
4102
4103
|
});
|
|
4103
4104
|
};
|
|
4104
|
-
this.
|
|
4105
|
+
this.showPopover = () => {
|
|
4105
4106
|
this.isOpen.set(true);
|
|
4106
4107
|
this.targetElement().showPopover({ source: this.hostElement() });
|
|
4107
4108
|
};
|