version 3 table cell styling

UI Components for JSF
Post Reply
snotmare
Posts: 6
Joined: 01 Sep 2011, 19:21

21 Oct 2011, 19:34

Greetings!

We currently are using version 2.2.1 for our customer website, but I've been tinkered a little bit with the latest dev release of primefaces (3.0.M3). I love a majority of the changes you guys are making. Great job! However, I'm a little miffed about one of them that I've run into issues with so far.

When using the dataTable, I provide my columns with width percentages like this...

Code: Select all

<p:dataTable... >
<p:column style="width: 25%;">Column1</p:column>
<p:column style="width: 50%;">Column2</p:column>
<p:column style="width: 25%;">Column3</p:column>
</p:dataTable>
In version 2.2.1, the width styling is applied directly to the <td> tag. In version 3, the style is applied to a <div> within the <td> tag like this...

Code: Select all

<table>
<tr>
<td><div style="width: 25%">Column1</div></td>
<td><div style="width: 50%">Column2</div></td>
<td><div style="width: 25%">Column3</div></td>
</tr>
</table>
The result is that my values are now sized to a percentage of the cell rather than the table.

Is this the way table cells will work going forward? If so, how can I apply a style directly to the cell? Also, various other JSF libraries apply the style directly to the cell (tomahawk comes to mind), so switching to primefaces would make that a little harder.

What are the chances that you guys will change this back?

cagatay.civici
Prime
Posts: 18616
Joined: 05 Jan 2009, 00:21
Location: Cybertron
Contact:

21 Oct 2011, 19:41

Set your table width to auto to make this behave as expected, divs in th are vital to make several functionalities work cross browser.

Post Reply

Return to “PrimeFaces”

  • Information
  • Who is online

    Users browsing this forum: No registered users and 63 guests