Bootstrap for Seaside question
Posted by
Torsten Bergmann on
Nov 25, 2013; 11:20am
URL: https://forum.world.st/Bootstrap-for-Seaside-question-tp4725015.html
>Bootstrap for Seaside is really cool, it allows to quickly build something that looks very polished. Thanks Torsten!
You're welcome. In return you should send give a screenshot and short description
for the Pharo success story page. The more showcases we have the better it is...
Regarding your question:
#tbsButton returns a button as the name says.
TBSButtonTag is a subclass of WAButtonTag because the offical examples
are also using <button>
See
http://getbootstrap.com/components/#btn-groupsBut a button should also support #callback:
So it is not an anchor by default.
Make sure to have a #form: around it and #children is correct. Otherwise
callbacks will not work.
Note: you can also leave out the whole bootstrap wrapping part and use
Bootstrap styles directly, for instance with an anchor:
html anchor
class: 'btn btn-default';
callback: ...
with: []
Haven tested since I have no image at hand - but should work out of the box.
One could easily wrap this into a #tbsAnchorButton and "WAAnchorTag subclass: #TBSAnchorButtonTag"
supporting the same API.
Contribute code + tests if you like. I added you on STHub.
Bye
T.