Re: [CSS3] ::outside and table amnd/or ruby elements

> [Original Message]
> From: Ian Hickson <ian@hixie.ch>
>
> On Mon, 26 Apr 2004, Ernest Cline wrote:
> >
> > Considering the potential effects upon the generation
> > of anonymous elements, the application of ::outside
> > to elements with a 'display' value of any of "table-cell",
> > "table-caption", "table-row-group", "table-header-group",
> > "table-footer-group", "table-column", "table-column-group",
> > "table-row", "ruby-base", "ruby-text", "ruby-base-group",
> > and "ruby-text-group" needs to carefully considered if
> > not outright banned.
>
> Why would it be any different than having a <div> element in the same
> place with the same type?

Example:

<style>
  td::outside { /* */}
</style>
<table>
  <tr>
    <td>X</td>
  </tr>
<table>


Now in the flow there is an anonymous box <td::outside> between
a table-row element <tr> and a table-cell element <tr>
If <td::outside> is anything other than an:table-cell,
there will be additional anonymous boxes generated
between <tr> and <td::outside> by the CSS table model [1]
If <td::outside> is anything other than a table-row.
there will be additional anonymous boxes generated
between <td::outside> and <td>.

Further reflection has caused me to consider that this could be
remedied by adding the following CSS:
  td::outside {display:table-cell}
  td {display: block}
to avoid generating the extra anonymous boxes, but it would
be a good idea to point out the problem and a potential
solution  that works reasonably well for this case.  However,
note that in solving the problem, I have side-stepped it,
as <td> is no longer a table-cell.

[1] http://www.w3.org/TR/CSS21/tables.html#q2

Received on Monday, 26 April 2004 19:38:10 UTC