Is it possible to skip errors for -linear-gradient syntax

Post here if your topic is about CSS HTML Validator but doesn't fit in another forum.
Post Reply
User avatar
sitestepper
Rank II - Novice
Rank II - Novice
Posts: 29
Joined: Tue Aug 08, 2006 12:38 pm
Location: Antwerpen - Belgium
Contact:

Is it possible to skip errors for -linear-gradient syntax

Post by sitestepper » Tue Aug 30, 2011 3:50 am

Hi,

Is it possible to turn the errors produced when using one of the following lines into a message (like you do with 'Found the unknown proprietary Safari/WebKit property "-webkit-box-shadow". Unknown proprietary Safari/WebKit properties that begin with a dash are ignored and their values are not checked. Proprietary Safari/WebKit properties may only work in Safari and WebKit based browsers and will probably not work in other browsers like Firefox, Internet Explorer, and Opera. There may be other proprietary Safari/WebKit properties. This message is displayed only once.') ?

background: -moz-linear-gradient(top, top, white, #d5eaff 95%);
background: -webkit-gradient(linear, top, white, #d5eaff 95%);
background: -webkit-linear-gradient( top, white, #d5eaff 95%);
background: -o-linear-gradient(top, top, white, #d5eaff 95%);
background: linear-gradient(top, top, white, #d5eaff 95%);

I am using this syntax to produce gradients and need the various syntax lines for different browsers (maybe I don't need all of them, but you get the picture).

Thanks
Author of Sitestepper - the web maintenance program.

User avatar
Albert Wiersch
Site Admin
Site Admin
Posts: 3347
Joined: Sat Dec 11, 2004 9:23 am
Location: Near Dallas, TX
Contact:

Re: Is it possible to skip errors for -linear-gradient synta

Post by Albert Wiersch » Tue Aug 30, 2011 9:06 am

Hello,

You could disable messages like these using "Exact Text Match" disable option:
The value "-moz-linear-gradient(top, top, white, #d5eaff 95%)" is invalid.
The value "-webkit-gradient(linear, top, white, #d5eaff 95%)" is invalid.

But disabling the other errors (like below) would disable all the checking for the "background" property:
The value for the shorthand "background" property is invalid. CSS2.1 allows this value to be "['background-color' || 'background-image' || 'background-repeat' || 'background-attachment' || 'background-position']". CSS3 allows this value to be "[ <bg-layer> , ]* <final-bg-layer>", where <bg-layer> is "<bg-image> || <bg-position> || / <bg-size> || <repeat-style> || <attachment> || <bg-origin>" and <final-bg-layer> is "<bg-image> || <bg-position> || / <bg-size> || <repeat-style> || <attachment> || <bg-origin> || <'background-color'>". This shorthand property can set most background properties.

For the next major release (v11), I'm targeting improved HTML5 & CSS3 checking & better customization ability. If you'd like to test this out using a BETA build, then please email me at support at htmlvalidator dot com. I have some ideas for v11 that can better help with this problem and I'd be happy to test/try them with you.
Image
Albert Wiersch

User avatar
Albert Wiersch
Site Admin
Site Admin
Posts: 3347
Joined: Sat Dec 11, 2004 9:23 am
Location: Near Dallas, TX
Contact:

Re: Is it possible to skip errors for -linear-gradient synta

Post by Albert Wiersch » Wed Oct 05, 2011 11:06 am

Hello,

I'd like to work on this for V11 now. Could you email me some of your CSS stylesheets that use gradient values? It would be helpful. Thanks!

UPDATE: I'd still like to test those style sheets, but the public v11 BETA should now accept these as images - though the gradient parameters (what's in the parenthesis) are not currently checked. It looks like the "CSS Image Values and Replaced Content Module Level 3" is only in the "Editor's Draft" status/stage.
Image
Albert Wiersch

User avatar
sitestepper
Rank II - Novice
Rank II - Novice
Posts: 29
Joined: Tue Aug 08, 2006 12:38 pm
Location: Antwerpen - Belgium
Contact:

Re: Is it possible to skip errors for -linear-gradient synta

Post by sitestepper » Thu Oct 06, 2011 2:32 am

Albert, the CSS file has been emailed.

Erik
Author of Sitestepper - the web maintenance program.

User avatar
Albert Wiersch
Site Admin
Site Admin
Posts: 3347
Joined: Sat Dec 11, 2004 9:23 am
Location: Near Dallas, TX
Contact:

Re: Is it possible to skip errors for -linear-gradient synta

Post by Albert Wiersch » Sat Oct 08, 2011 8:34 am

sitestepper wrote:Albert, the CSS file has been emailed.
Thanks!

Please try the public BETA here and let me know how it works:
http://www.htmlvalidator.com/freebeta/
Image
Albert Wiersch

Post Reply