cgarvis / angular-toggle-switch

AngularJS Toggle Switch
http://cgarvis.github.io/angular-toggle-switch
MIT License
160 stars 124 forks source link

bug: disabled property is evaluated as string rather than boolean #46

Closed intellix closed 10 years ago

intellix commented 10 years ago

If you add the attribute disabled="false", the switch is disabled because it's evaluated as a string "false" (which is true). Also when re-enabled, it doesn't remove the disabled class. Created a plunkr, which I think would be good adding to README.md to help debugging in the future as there is currently no playground.

http://plnkr.co/edit/LOqRcb2woOjlkllrv8Am?p=preview