When tinkering around with this module I realized that if I remove the
<span class="clear">
that gets appended, as well as add a little bit of css code; I can totally have cool vertical tabs rendered.
Only thing is that I removed the "clear span" with firebug post page render, now i have to actually edit the tabs.js!
Has anyone else tinkered with this idea? I was going to roll a new module for vertical tabs but this came so close ... I don't see the point in replicating all the bits when something so simple could make this module do vert and horiz.
Im not sure but I think I just need to tweak the if statements related to the "span class" appending, so they avoid my vertical tabs classes?
Cheers ^__^
Comments
Comment #1
nedjoInteresting idea. It would need something like:
* another setting on the settings page, indicating the style (horizontal - the default - or vertical).
* pass the status of this setting with the Drupal.settings data already passed by tabs.module.
* conditionally load the vertical tabs css file based on this setting.
* in tabs.js, read the setting and conditionally append content.
I'd welcome a patch.
Comment #2
Macronomicus commentedI was able to do it even easier than I thought it would be, and without touching the js file...
On the drupal-tabs.css I changed line 27 & down to
Just have to make sure to apply the correct class to an outer div surrounding the tabs. Dirty but easy!
I still have to stylize the other css a bit more for handling vertical tabs nicely. I'll put that up as soon as its done. ^_^
Comment #3
wim leersYep, I did some experimentation with this myself and it's indeed easier than it looks :)
I'll review and further work on this patch after I've ported my modules to D6.
Comment #4
wim leersWe now have Vertical Tabs in D7 core.
Comment #5
Macronomicus commentedSweet!