1
0
mirror of https://github.com/bitwarden/browser synced 2025-12-17 00:33:44 +00:00

UIF - Prefer signal & change detection (#16940)

This commit is contained in:
Oscar Hinton
2025-10-21 18:52:40 +02:00
committed by GitHub
parent d3fc20f8b9
commit 65da23feaa
135 changed files with 503 additions and 51 deletions

View File

@@ -22,6 +22,8 @@ export const TOOLTIP_DATA = new InjectionToken<TooltipData>("TOOLTIP_DATA");
/**
* tooltip component used internally by the tooltip.directive. Not meant to be used explicitly
*/
// FIXME(https://bitwarden.atlassian.net/browse/CL-764): Migrate to OnPush
// eslint-disable-next-line @angular-eslint/prefer-on-push-component-change-detection
@Component({
selector: "bit-tooltip",
templateUrl: "./tooltip.component.html",

View File

@@ -39,7 +39,7 @@ export class TooltipDirective implements OnInit {
*/
readonly tooltipPosition = input<TooltipPositionIdentifier>("above-center");
private isVisible = signal(false);
private readonly isVisible = signal(false);
private overlayRef: OverlayRef | undefined;
private elementRef = inject(ElementRef);
private overlay = inject(Overlay);

View File

@@ -12,6 +12,8 @@ import { Observable, Subject } from "rxjs";
import { TooltipDirective } from "./tooltip.directive";
// FIXME(https://bitwarden.atlassian.net/browse/CL-764): Migrate to OnPush
// eslint-disable-next-line @angular-eslint/prefer-on-push-component-change-detection
@Component({
standalone: true,
imports: [TooltipDirective],