Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

HTML5 validation (Expected a CSS media feature but saw device-width instead) #98

Closed
damianobarbati opened this issue Oct 26, 2017 · 2 comments · May be fixed by itgalaxy/favicons#289
Closed

Comments

@damianobarbati
Copy link

Can favicons plugin move to css media features instead of using device-width?

Error: Bad value (device-width: 320px) and (device-height: 480px) and (-webkit-device-pixel-ratio: 1) for attribute media on element link: Expected a CSS media feature but saw device-width instead.
From line 7, column 1396; to line 7, column 1584
icon.ico"><link rel="apple-touch-startup-image" media="(device-width: 320px) and (device-height: 480px) and (-webkit-device-pixel-ratio: 1)" href="/build/icons/apple-touch-startup-image-320x460.png"><link 
Error: Bad value (device-width: 320px) and (device-height: 480px) and (-webkit-device-pixel-ratio: 2) for attribute media on element link: Expected a CSS media feature but saw device-width instead.
From line 7, column 1585; to line 7, column 1773
x460.png"><link rel="apple-touch-startup-image" media="(device-width: 320px) and (device-height: 480px) and (-webkit-device-pixel-ratio: 2)" href="/build/icons/apple-touch-startup-image-640x920.png"><link 
Error: Bad value (device-width: 320px) and (device-height: 568px) and (-webkit-device-pixel-ratio: 2) for attribute media on element link: Expected a CSS media feature but saw device-width instead.
From line 7, column 1774; to line 7, column 1963
x920.png"><link rel="apple-touch-startup-image" media="(device-width: 320px) and (device-height: 568px) and (-webkit-device-pixel-ratio: 2)" href="/build/icons/apple-touch-startup-image-640x1096.png"><link 
@paulcalabro
Copy link

I came across this myself. I think this change actually has to happen upstream:

https://github.com/evilebottnawi/favicons/blob/4eccf831d70151fc5a2be35ba8be64910f58a00d/config/html.json

@joepagan
Copy link

This is still happening today.

You can satisfy w3c validator by turning off the appleStartup favicons:
appleStartup: false,

It looks like the parent evilebottnawi/favicons` script hasn't changed since 2016, so, need some sort of file replacement, or, a specific version of that.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants