From b9d2fc79679972789b2201057f8bdc54df5974e6 Mon Sep 17 00:00:00 2001 From: jtm Date: Sat, 3 Mar 2012 18:14:31 +0000 Subject: [PATCH] checkpoint --- lesscpy/lessc/lexer.py | 1 + lesscpy/plib/property.py | 1 - lesscpy/test/css/ws.css | 25 +++++++++++++++++++++ lesscpy/test/css/ws.min.css | 8 +++++++ lesscpy/test/less/ws.less | 45 +++++++++++++++++++++++++++++++++++++ 5 files changed, 79 insertions(+), 1 deletion(-) create mode 100644 lesscpy/test/css/ws.css create mode 100644 lesscpy/test/css/ws.min.css diff --git a/lesscpy/lessc/lexer.py b/lesscpy/lessc/lexer.py index aeeb380..0d4e1ce 100644 --- a/lesscpy/lessc/lexer.py +++ b/lesscpy/lessc/lexer.py @@ -167,6 +167,7 @@ class LessLexer: def t_t_ws(self, t): r'[ \t\f\v]+' + t.value = ' ' return t def t_t_popen(self, t): diff --git a/lesscpy/plib/property.py b/lesscpy/plib/property.py index ddc3f29..de38121 100644 --- a/lesscpy/plib/property.py +++ b/lesscpy/plib/property.py @@ -47,7 +47,6 @@ class Property(Node): if p == ',' else p for p in self.parsed] - style = ''.join([p.fmt(fills) if hasattr(p, 'fmt') else str(p) diff --git a/lesscpy/test/css/ws.css b/lesscpy/test/css/ws.css new file mode 100644 index 0000000..9534e15 --- /dev/null +++ b/lesscpy/test/css/ws.css @@ -0,0 +1,25 @@ +.whitespace { + color: white; +} +.whitespace { + color: blue; +} +.whitespace { + color: green; +} +.whitespace { + color: pink; +} +.whitespace { + color: yellow; +} +.whitespace { + color: black; +} +.white, .space, .mania { + color: white; +} +.newlines { + background: the, great, wall; + border: 2px solid black; +} diff --git a/lesscpy/test/css/ws.min.css b/lesscpy/test/css/ws.min.css new file mode 100644 index 0000000..1aa9ef7 --- /dev/null +++ b/lesscpy/test/css/ws.min.css @@ -0,0 +1,8 @@ +.whitespace{color:white;} +.whitespace{color:blue;} +.whitespace{color:green;} +.whitespace{color:pink;} +.whitespace{color:yellow;} +.whitespace{color:black;} +.white,.space,.mania{color:white;} +.newlines{background:the,great,wall;border:2px solid black;} diff --git a/lesscpy/test/less/ws.less b/lesscpy/test/less/ws.less index e69de29..59d0597 100644 --- a/lesscpy/test/less/ws.less +++ b/lesscpy/test/less/ws.less @@ -0,0 +1,45 @@ +/* + Whitespace +*/ +.whitespace + { color: white; } + +.whitespace +{ + color: blue; +} +.whitespace +{ + color: green; + + + + + + + + + + +} + .whitespace +{ color: pink; } + +.whitespace{color:yellow;} +.whitespace { color : black ; } + +.white, +.space, +.mania +{ color: white; } +.newlines { + background: the, + great, + wall; + border: 2px + solid + black; +} +.empty { + +}