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

Support Namespaced Selectors (level 3) #65

Open
jiggliemon opened this issue Nov 14, 2011 · 3 comments
Open

Support Namespaced Selectors (level 3) #65

jiggliemon opened this issue Nov 14, 2011 · 3 comments

Comments

@jiggliemon
Copy link

Slick doesn't support CSS3 namespace selectors:

Slick.find('ns|a') // [<ns:a></ns:a>]
@subtleGradient
Copy link
Member

The workaround is to use an escaped colon. That should work in all browsers. Iirc we should have some specs for this in the SlickSpec already.

— Thomas Aylott - SubtleGradient - MooTools - Sencha (from iPhone)

On Nov 14, 2011, at 3:55 PM, [email protected] wrote:

Slick doesn't support CSS3 namespace selectors:

Slick.find('ns|a') // [<ns:a></ns:a>]

Reply to this email directly or view it on GitHub:
#65

@jiggliemon
Copy link
Author

The one problem I see is that the standard "select all" selector doesn't work using the :_;
None of these work:
Slick.find('ns|_') Slick.find('ns\:*') Slick.find('ns\\:*')

@subtleGradient
Copy link
Member

good point.
You could implement that with a custom pseudoclass though.
e.g. Slick.search(document, '*:ns(foo)')

Not ideal, obviously, but it would work.

The implementation of the custom pseudo could be something like function(ns){ return this.nodeName.split(':')[0] == ns }. There may be a faster way to do it, but that should work.

Thomas Aylott SubtleGradient MooTools Sencha

On Nov 15, 2011, at 1:23 PM, Chase wrote:

The one problem I see is that the standard "select all" selector doesn't work using the :_;
None of these work:
Slick.find('ns|_') Slick.find('ns\:*') Slick.find('ns\\:*')


Reply to this email directly or view it on GitHub:
#65 (comment)

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

No branches or pull requests

2 participants