Annular Method of Angular Material Design

Asked

Viewed 83 times

0

I have a menu of the angular material design that when it opens it focuses on the first menu item, I would like to remove this method.

I saw on the web site of angular material that this method has the following attributes:

Methods
focusFirstItem
Focus the first item in the menu.

Parameters
origin

FocusOrigin = 'program' 
Action from which the focus originated. Used to set the correct styling.

How can I override this method? I must create this method in my Component.ts?

tried something like

focusFirstItem(origin){
 return false
}
  • 1

    What is the type of menu that focuses on the first item? https://material.angular.io/components/menu/overview, this one displays the list without selecting any

  • I’m already using this, but the first item comes with a blue border, probably caused by the call of this method "focusFirstItem"

  • should not come with the blue border as it is not the behavior shown in the documentation. You can edit the question with its code scenario?

No answers

Browser other questions tagged

You are not signed in. Login or sign up in order to post.