Design and CSS styles
Version 5.x > Design and CSS styles > Media library display CSS View modes: 
User avatar
Member
Member
paulant1-me - 9/16/2011 10:24:04 AM
   
Media library display CSS
I have added the Media Gallery webpart to a page, following all the instructions, but it is displaying all the images in a single column rather than the rows and columns shown in the example. I haven't changed any settings and don't understand what i've done wrong. There doesn't appear to be any support for this.

Can anybody help please?

User avatar
Kentico Developer
Kentico Developer
kentico_ondrejv - 9/19/2011 2:24:48 AM
   
RE:Media library display CSS
Hello,

The Media Gallery items are CSS styles driven, in the meaning that their layout is created in a transformation and you can set CSS styles for particular elements in there.

By default (I mean the Corporate site sample site), the media item is enwrapped in the DIV element with "mediaItem" CSS class. There is the following CSS definition for it in the CSS stylesheet (among the others):

float: left;

This basically does the trick and floats the elements as per your needs.

Best regards
Ondrej Vasil

User avatar
Member
Member
paulant1-me - 9/22/2011 10:55:29 AM
   
RE:Media library display CSS
Excellent, I've introduced a 'mediaItem' style sheet and i'm now back on track.
Many thanks for your help.