[Prototype-core] Re: :not() selector bugs
I fixed the fix. I'm not sure how to make a properly formatted diff though. the issue was |(?=\s)|(?=:) needed to be (?=(\s|:)) http://dev.rubyonrails.org/attachment/ticket/9696/selector.diff?format=txt --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Prototype: Core group. To post to this group, send email to prototype-core@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/prototype-core?hl=en -~--~~~~--~~--~--~---
[Prototype-core] Re: :not() selector bugs
On 9/26/07, Wiktor Ihárosi [EMAIL PROTECTED] wrote: Should I create a ticket in trac? Yeah, it would be best if you attached a diff to that ticket that adds some failing tests to the current unit test suite for selector module. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Prototype: Core group. To post to this group, send email to prototype-core@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/prototype-core?hl=en -~--~~~~--~~--~--~---
[Prototype-core] Re: :not() selector bugs
The CSS2 and CSS3 specs disagree on this, annoyingly enough. [1] I'd originally written :not to throw an exception on selectors with more than one token, but then I saw the conflicting definitions and relented. All the other major libraries seem to allow this confusing syntax. Not being able to use the descendant combinator after a :not clause, however, is a bug. Wiktor, feel free to report it; I'll try to fix it before 1.6 final. Cheers, Andrew [1] http://www.w3.org/TR/REC-CSS2/selector.html#q2 On Sep 26, 10:51 am, kangax [EMAIL PROTECTED] wrote: Interesting, From w3c specs (http://www.w3.org/TR/2001/CR-css3-selectors-2003/ #negation): The negation pseudo-class is a functional notation taking a simple selector (excluding the negation pseudo-class itself and pseudo- elements) as an argument. Now what is simple selector (http://www.w3.org/TR/2001/CR-css3- selectors-2003/#simple-selectors-dfn) ? A simple selector is either a type selector, universal selector, attribute selector, ID selector, content selector, or pseudo-class. One pseudo-element may be appended to the last sequence of simple selectors. Looks like your 'a:not(a[rel$=nofollow]' is not quite a simple selector (but rather a combination of type and attribute ones) Besides, a:not(a[rel^=external]) doesn't make sense in the first place (just like div:not(div) which will never match) : ) Why select a that are not a with some condition when you could just specify condition on its own. It will be tested against all a anyway: a:not([rel^=external]) Hope this helps, kangax --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Prototype: Core group. To post to this group, send email to prototype-core@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/prototype-core?hl=en -~--~~~~--~~--~--~---
[Prototype-core] Re: :not() selector bugs
Andrew Dupont wrote: Not being able to use the descendant combinator after a :not clause, however, is a bug. Wiktor, feel free to report it; I'll try to fix it before 1.6 final. Thx Andrew! Here is the ticket with the attached diff: http://dev.rubyonrails.org/ticket/9696 --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Prototype: Core group. To post to this group, send email to prototype-core@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/prototype-core?hl=en -~--~~~~--~~--~--~---