I need a visual element on my web page to resemble a button, with an optional dropdown element on the right end. Clicking the main button will execute some default action, while clicking (or hovering) over the down arrow on the right end of the button will cause a dropdown menu to appear with variations on the action, and clicking on one of those will invoke various javascript methods.
|-----------------------------|
| Take Action | \/ |
|-----------------------------|
|-----------------------------|
| Take Action | \/ |
|-----------------------------|
| variant 1 |
| variant 2 |
| variant 3 |
|----------------------|
Before I go write this myself, has anyone else seen something like this as an open source bit of code I can reuse?