Re: [css-grid] Does <custom-ident> in grid-template-rows/grid-template-columns exclude auto/minmax/subgrid?

On Sun, Mar 2, 2014 at 2:31 AM, Daniel Holbert <dholbert@mozilla.com> wrote:
> On 02/26/2014 01:25 PM, Tab Atkins Jr. wrote:
>>> Question: Should "minmax" [...] "auto", and "subgrid" be accepted as valid
>>> <custom-ident> values, in the <line-names> list for the
>>> grid-template-columns and grid-template-rows properties?
> [...]
>> Correct, they're not valid.  You're right that they'd be unambiguous,
>> but I don't think it's necessary to care.
>
> Followup question:
>
> When a UA is parsing the grid-template-rows / grid-template-columns
> properties **as subcomponents of the "grid" shorthand property**, should
> it consider the keywords "rows", "columns", and "dense" as being
> disallowed <custom-ident> line-names?
>
> (These keywords aren't normally disallowed <custom-ident>s, but in the
> context of the shorthand, they might have to be, since they are valid
> keywords for other sub-properties of the shorthand. There'd be no
> ambiguity if we allowed them here, since as <custom-ident> values,
> they'd be parenthesized. But I can imagine hypothetical shorthand
> properties where there would be ambiguity.)

Hm, that's a good question.  Technically, the definition of
<custom-ident> means that something which is allowed in a longhand is
illegal in a shorthand, which isn't great.  It means we can't always
serialize a shorthand.

I wonder if it's better to change the definition of <custom-ident> to
not do this?  Instead, maybe it would only disallow the keywords that
it can be juxtaposed with.  That seems hard to define, though.  Hm.

~TJ

Received on Monday, 3 March 2014 19:18:53 UTC