Dev.Opera - Follow the standards, break the rulesDev.Opera - Follow the standards, break the rules

Login

Lost password?

Forums » Opera Dragonfly Discussions

Discuss Opera Dragonfly, Opera's new developer tools.

Note: You need to login to post in the forums. if you don't have an account you first need to sign up.

By garmt anchor Thursday, 8. May 2008, 08:30:34

avatar

CSS error reported while CSS is OK

Very cool, very useful, this Dragonfly. I'll test it more thoroughly in due time. Right now, I just noticed a minor oddity: I get a CSS error message in the Console, saying:

Invalid value for property: content

Line 340:
h1 cite:after, h2 cite:after { content: none; }
---------------------------------------------^

AFAIK, there's nothing wrong with content: none;

By shoust anchor Thursday, 8. May 2008, 09:15:46

avatarI think the general idea is that you pass a text string to the content: property. Does an empty string work?

By fearphage anchor Thursday, 8. May 2008, 13:56:53

avatarI think shoust is correct. background-color: none is also a popular error. You have to find the situational value that is equivalent to none. The content property expects strings so none to it is the empty string. Background color expects colors so none to it is transparent.

By Schalandra anchor Thursday, 8. May 2008, 16:07:17

avatarI'm afraid, but garmt is right. content: none is defined in "CSS3 Generated and Replaced Content Module" chapter 11 "Inserting and replacing content with the 'content' property".

see: http://www.w3.org/TR/css3-content/#inserting3

By fearphage anchor Thursday, 8. May 2008, 18:00:02

avatar

Originally posted by Schalandra:

content: none is defined in "CSS3 Generated and Replaced Content Module"
Opera currently has full support for css 2.1. It supports various parts of css3 but not all of it yet.

By Andrew Gregory anchor Friday, 9. May 2008, 02:31:09

avatarcontent:none is valid CSS 2.1 too:

http://www.w3.org/TR/CSS21/generate.html#content

By porneL anchor Friday, 9. May 2008, 12:39:42

avatarI think it's just bug/lack of support in Opera, not Dragonfly reporting.

By fearphage anchor Friday, 9. May 2008, 13:30:07

avatar

Originally posted by Andrew Gregory:

content:none is valid CSS 2.1
I stand corrected partially. In CSS 2.1, content is only supported for :before and :after.

Originally posted by w3c:

This property is used with the :before and :after pseudo-elements to generate content in a document.
http://www.w3.org/TR/CSS21/generate.html#content

Post edited Friday, 9. May 2008, 17:23:56

By xErath anchor Wednesday, 14. May 2008, 22:57:13

avatarThis bug was reported to Opera in 2005 :smile:
Thanks, no need to do it again.

Moderators: dstorey | operadev | chrismills