Chris (factoryjoe) wanted to be able to theme node previews differently from the other node views. I decided to add a div around the whole preview area which includes one or two node views, trimmed and not trimmed. And I went ahead and put the whole thing in a themeable function since the is a lot of HTML there.

CommentFileSizeAuthor
node.module_1.diff2.34 KBdrumm
Support from Acquia helps fund testing for Drupal Acquia logo

Comments

rkendall’s picture

I think this is a good idea. The more themeable the better, as long as there is some sensible overall use of class names etc. ("preview" does make sense to me)

Just one comment/question, does Drupal have some kind of overall plan for the use of HTML class/id names etc.? ...and how div's are nested in the output HTML as well?

I like the idea of as much being themeable by CSS as possible, but maybe we also need to be careful to keep the CSS themeing as simple and consistent as possible - as well.

...just trying to get the bigger picture in mind.

Steven’s picture

Applied to HEAD.

Bèr Kessels’s picture

I like the idea, bbut have some small issues:
H3 is not correct. IMO it should be h2
If you use H2 you can even use theme_box, thus reducing the code a lot and re-using general APIS. Also, you will then have less HTML in your code, which is always a good thing.

Bèr

Anonymous’s picture