-
Notifications
You must be signed in to change notification settings - Fork 22
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
URI Traversing misses uris within functions #59
Comments
I'm able to fix this in kotlin with something like: private inner class CompleteCSSVisitorForUrl(visitor: ICSSUrlVisitor) : CSSVisitorForUrl(visitor) {
override fun onDeclaration(decl: CSSDeclaration) {
val expr = decl.expression
onExpression(decl, expr)
}
private fun onExpression(decl: CSSDeclaration, expr: CSSExpression) {
for (member in expr.allMembers) when (member) {
is CSSExpressionMemberTermURI -> {
visitor.onUrlDeclaration(null, decl, member)
}
is CSSExpressionMemberFunction -> {
member.expression?.let { onExpression(decl, it) }
}
}
}
} Obviously this isn't quite correct WRT to the visitor interface, but works for my usecase. |
Thank you for that snippet 👍 |
Ah forget half of my previous comment. I just fix the |
This is part of the 6.2.3 release that is building as I type |
Wow thanks for the quick turnaround and release here! |
Example CSS:
I would expect that this example: https://github.com/phax/ph-css/blob/master/ph-css/src/test/java/com/helger/css/supplementary/wiki/WikiVisitDataUrls.java
Would print out urls for this snippet, but it does not.
The text was updated successfully, but these errors were encountered: