Skip to content

Commit

Permalink
I don’t know what I am doing
Browse files Browse the repository at this point in the history
  • Loading branch information
alanhogan committed Jun 4, 2012
1 parent 3baf6df commit 7b3abdb
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions lib/kss.coffee
Expand Up @@ -15,9 +15,9 @@ class KssStateGenerator
for stylesheet in document.styleSheets for stylesheet in document.styleSheets
idxs = [] idxs = []
for rule, idx in stylesheet.cssRules for rule, idx in stylesheet.cssRules
if (rule.type == CSSRule.STYLE_RULE) && pseudos.test(rule.selectorText) while (rule.type == CSSRule.STYLE_RULE) && pseudos.test(rule.selectorText)
replaceRule = (matched, stuff) -> replaceRule = (matched, stuff) ->
return ".pseudo-class-" + matched.replace(':', '') return matched.replace(/\:/g, '.pseudo-class-')
@insertRule(rule.cssText.replace(pseudos, replaceRule)) @insertRule(rule.cssText.replace(pseudos, replaceRule))


# Takes a given style and attaches it to the current page. # Takes a given style and attaches it to the current page.
Expand Down

0 comments on commit 7b3abdb

Please sign in to comment.