twitter/bootstrap — pull request #523 by brennanmceachran (2011-11-02 05:29:49+00:00)
Title: Patch 3

Adding and removing classes when using $().button so you can style each state differently...

Also, giving $().button('toggle') some love if there is "active" text in the element. Might help with the follow/unfollow stuff here: #522

`('.btn').button('toggle');` now performs a text swap.

`$('.btn').button('saved');` adds a class 'state-savedText'
`$('.btn').button('love');` adds a class 'state-loveText'
`$('.btn').button('hate');` adds a class 'state-hateText'
etc...

So you can style each state differently...