Angular2, what is the correct way to disable an anchor element?

前端 未结 10 1244
死守一世寂寞
死守一世寂寞 2020-11-27 17:51

I\'m working on an Angular2 application, and I need to display -- but disable an HTML element. What is the corr

10条回答
  •  春和景丽
    2020-11-27 18:33

    I have used

    tabindex="{{isEditedParaOrder?-1:0}}" 
    [style.pointer-events]="isEditedParaOrder ?'none':'auto'" 
    

    in my anchor tag so that they can not move to anchor tag by using tab to use "enter" key and also pointer itself we are setting to 'none' based on property 'isEditedParaO rder' whi

提交回复
热议问题