Angular2 disable button

前端 未结 10 1770
萌比男神i
萌比男神i 2020-12-02 10:03

I know that in angular2 I can disable a button with the [disable] attribute, for example:

10条回答
  •  醉酒成梦
    2020-12-02 11:08

     
    

    .ts code

    setStyles() 
    {
        let styles = {
    
        'action-button-disabled': this.model.IsConnected() == false  
      };
      return styles;
    }
    

提交回复
热议问题