- From: Sebastian Zartner <sebastianzartner@gmail.com>
- Date: Thu, 3 Mar 2016 23:04:33 +0100
- To: "Tab Atkins Jr." <jackalmage@gmail.com>
- Cc: www-style list <www-style@w3.org>
On 3 March 2016 at 20:57, Tab Atkins Jr. <jackalmage@gmail.com> wrote: > On Thu, Mar 3, 2016 at 5:37 AM, Sebastian Zartner > <sebastianzartner@gmail.com> wrote: >> The description for the image() function says that it allows to use a >> solid color as an image. >> >> Though its syntax is defined as >> >> image( [ [ <image> | <string> ]? , <color>? ]! ) >> >> meaning that colors are only allowed as fallback values. > > How are you getting this? The syntax marks both parts as optional, > and just requires that you specify one of them. So image(blue) is > valid per that grammar. > >> Furthermore, the syntax for the image() function suggests that the >> comma stands for its own and is not influenced by the question mark >> multiplier after <color>. > > Correct, but https://drafts.csswg.org/css-values/#comb-comma clarifies > how commas work in CSS grammars - they're automatically required to be > omitted unless they're actually separating things. Ah, I didn't know that. So then it's obviously valid. Regarding my second point about extending <image> to accept <color> values, I saw that you had the same idea some years ago.[1] It looks like fantasai was reluctant to this idea but the thread didn't come to a conclusion and as far as I can see this is also not mentioned in any WG minutes. So, maybe this topic should be revived? Sebastian [1] https://lists.w3.org/Archives/Public/www-style/2010Nov/0380.html
Received on Thursday, 3 March 2016 22:05:22 UTC