- From: Lea Verou via GitHub <sysbot+gh@w3.org>
- Date: Mon, 09 Apr 2018 11:53:02 +0000
- To: public-houdini-archive@w3.org
LeaVerou has just created a new issue for https://github.com/w3c/css-houdini-drafts: == [css-paint-api] Rename paint(name, args) to paint-name(args) == The way the Paint API currently works is that it gives authors a `paint()` function, whose first argument is an `<ident>` for the name of painting operation. However, putting the name of painting in the function call has several benefits: - It makes the call easier to read, since the paint name is not really an argument, it's conceptually part of the function. - It makes web developers feel that they are creating an actual CSS function, instead of merely extending an existing function. - It actually reads nicer, since "paint" combines nicely with the name of what is being painted. Compare (examples from the spec): ```css .logo { background-image: paint(company-logo); } .chat-bubble { background-image: paint(chat-bubble, blue); } ``` vs: ```css .logo { background-image: paint-company-logo(); } .chat-bubble { background-image: paint-chat-bubble(blue); } ``` I recall mentioning this in person to some Houdini folks ages ago, and they agreed, but I never made an issue so I guess it was forgotten. Please view or discuss this issue at https://github.com/w3c/css-houdini-drafts/issues/751 using your GitHub account
Received on Monday, 9 April 2018 11:53:06 UTC