src/app/directives/steal-focus.directive.ts

Metadata

Relationships

Depends on

No results matching.

Index

Methods
HostListeners

Constructor

constructor()

HostListeners

click
Arguments : '$event'

For some reason newest version of Clarity v17.0.1 is stealing focus when clicking on the input inside of the clr-tree-view This is workaround

Methods

onClick
onClick(event: any)
Decorators :
@HostListener('click', ['$event'])

For some reason newest version of Clarity v17.0.1 is stealing focus when clicking on the input inside of the clr-tree-view This is workaround

Parameters :
Name Type Optional
event any No
Returns : void
import { Directive, HostListener } from '@angular/core'

@Directive({
  selector: '[appStealFocus]',
  standalone: false
})
export class StealFocusDirective {
  constructor() {}

  /**
   * For some reason newest version of Clarity v17.0.1 is stealing focus when
   * clicking on the input inside of the clr-tree-view
   * This is workaround
   */
  @HostListener('click', ['$event']) onClick(event: any) {
    event.target.focus()
  }
}

results matching ""

    No results matching ""