haml 2.2.24 → 3.0.0.beta.1

Sign up to get free protection for your applications and to get access to all the features.

Potentially problematic release.


This version of haml might be problematic. Click here for more details.

Files changed (168) hide show
  1. data/.yardopts +0 -1
  2. data/README.md +91 -151
  3. data/REMEMBER +11 -1
  4. data/Rakefile +73 -55
  5. data/VERSION +1 -1
  6. data/VERSION_NAME +1 -1
  7. data/bin/css2sass +7 -1
  8. data/bin/sass-convert +7 -0
  9. data/extra/haml-mode.el +2 -1
  10. data/lib/haml/buffer.rb +22 -4
  11. data/lib/haml/engine.rb +5 -1
  12. data/lib/haml/exec.rb +231 -46
  13. data/lib/haml/filters.rb +19 -8
  14. data/lib/haml/helpers.rb +47 -20
  15. data/lib/haml/helpers/action_view_extensions.rb +2 -4
  16. data/lib/haml/helpers/action_view_mods.rb +11 -8
  17. data/lib/haml/helpers/xss_mods.rb +13 -2
  18. data/lib/haml/html.rb +179 -48
  19. data/lib/haml/html/erb.rb +141 -0
  20. data/lib/haml/precompiler.rb +40 -15
  21. data/lib/haml/railtie.rb +1 -5
  22. data/lib/haml/root.rb +3 -0
  23. data/lib/haml/template.rb +4 -14
  24. data/lib/haml/util.rb +120 -30
  25. data/lib/haml/version.rb +25 -2
  26. data/lib/sass.rb +5 -1
  27. data/lib/sass/callbacks.rb +50 -0
  28. data/lib/sass/css.rb +40 -191
  29. data/lib/sass/engine.rb +170 -74
  30. data/lib/sass/environment.rb +8 -2
  31. data/lib/sass/error.rb +163 -25
  32. data/lib/sass/files.rb +31 -28
  33. data/lib/sass/plugin.rb +268 -87
  34. data/lib/sass/plugin/rails.rb +9 -4
  35. data/lib/sass/repl.rb +1 -1
  36. data/lib/sass/script.rb +31 -29
  37. data/lib/sass/script/bool.rb +1 -0
  38. data/lib/sass/script/color.rb +290 -23
  39. data/lib/sass/script/css_lexer.rb +22 -0
  40. data/lib/sass/script/css_parser.rb +28 -0
  41. data/lib/sass/script/funcall.rb +22 -3
  42. data/lib/sass/script/functions.rb +523 -33
  43. data/lib/sass/script/interpolation.rb +42 -0
  44. data/lib/sass/script/lexer.rb +169 -52
  45. data/lib/sass/script/literal.rb +58 -9
  46. data/lib/sass/script/node.rb +79 -1
  47. data/lib/sass/script/number.rb +20 -5
  48. data/lib/sass/script/operation.rb +49 -3
  49. data/lib/sass/script/parser.rb +162 -28
  50. data/lib/sass/script/string.rb +50 -2
  51. data/lib/sass/script/unary_operation.rb +25 -2
  52. data/lib/sass/script/variable.rb +21 -4
  53. data/lib/sass/scss.rb +14 -0
  54. data/lib/sass/scss/css_parser.rb +39 -0
  55. data/lib/sass/scss/parser.rb +683 -0
  56. data/lib/sass/scss/rx.rb +112 -0
  57. data/lib/sass/scss/script_lexer.rb +13 -0
  58. data/lib/sass/scss/script_parser.rb +25 -0
  59. data/lib/sass/tree/comment_node.rb +69 -27
  60. data/lib/sass/tree/debug_node.rb +7 -2
  61. data/lib/sass/tree/directive_node.rb +41 -35
  62. data/lib/sass/tree/for_node.rb +6 -0
  63. data/lib/sass/tree/if_node.rb +13 -1
  64. data/lib/sass/tree/import_node.rb +52 -27
  65. data/lib/sass/tree/mixin_def_node.rb +18 -0
  66. data/lib/sass/tree/mixin_node.rb +41 -6
  67. data/lib/sass/tree/node.rb +197 -70
  68. data/lib/sass/tree/prop_node.rb +152 -57
  69. data/lib/sass/tree/root_node.rb +118 -0
  70. data/lib/sass/tree/rule_node.rb +193 -96
  71. data/lib/sass/tree/variable_node.rb +9 -5
  72. data/lib/sass/tree/while_node.rb +4 -0
  73. data/test/benchmark.rb +5 -5
  74. data/test/haml/engine_test.rb +147 -10
  75. data/test/haml/{rhtml/_av_partial_1.rhtml → erb/_av_partial_1.erb} +1 -1
  76. data/test/haml/{rhtml/_av_partial_2.rhtml → erb/_av_partial_2.erb} +1 -1
  77. data/test/haml/{rhtml/action_view.rhtml → erb/action_view.erb} +1 -1
  78. data/test/haml/{rhtml/standard.rhtml → erb/standard.erb} +0 -0
  79. data/test/haml/helper_test.rb +91 -24
  80. data/test/haml/html2haml/erb_tests.rb +410 -0
  81. data/test/haml/html2haml_test.rb +210 -66
  82. data/test/haml/results/filters.xhtml +1 -1
  83. data/test/haml/results/just_stuff.xhtml +2 -0
  84. data/test/haml/spec_test.rb +44 -0
  85. data/test/haml/template_test.rb +22 -2
  86. data/test/haml/templates/helpers.haml +0 -13
  87. data/test/haml/templates/just_stuff.haml +2 -0
  88. data/test/haml/util_test.rb +48 -0
  89. data/test/sass/callbacks_test.rb +61 -0
  90. data/test/sass/conversion_test.rb +884 -0
  91. data/test/sass/css2sass_test.rb +99 -18
  92. data/test/sass/data/hsl-rgb.txt +319 -0
  93. data/test/sass/engine_test.rb +1049 -131
  94. data/test/sass/functions_test.rb +398 -47
  95. data/test/sass/more_results/more_import.css +1 -1
  96. data/test/sass/more_templates/more_import.sass +3 -3
  97. data/test/sass/plugin_test.rb +184 -10
  98. data/test/sass/results/compact.css +1 -1
  99. data/test/sass/results/complex.css +5 -5
  100. data/test/sass/results/compressed.css +1 -1
  101. data/test/sass/results/expanded.css +1 -1
  102. data/test/sass/results/import.css +3 -1
  103. data/test/sass/results/mixins.css +12 -12
  104. data/test/sass/results/nested.css +1 -1
  105. data/test/sass/results/options.css +1 -0
  106. data/test/sass/results/parent_ref.css +4 -4
  107. data/test/sass/results/script.css +3 -3
  108. data/test/sass/results/scss_import.css +15 -0
  109. data/test/sass/results/scss_importee.css +2 -0
  110. data/test/sass/script_conversion_test.rb +153 -0
  111. data/test/sass/script_test.rb +137 -70
  112. data/test/sass/scss/css_test.rb +811 -0
  113. data/test/sass/scss/rx_test.rb +156 -0
  114. data/test/sass/scss/scss_test.rb +871 -0
  115. data/test/sass/scss/test_helper.rb +37 -0
  116. data/test/sass/templates/alt.sass +2 -2
  117. data/test/sass/templates/bork1.sass +2 -0
  118. data/test/sass/templates/bork3.sass +2 -0
  119. data/test/sass/templates/bork4.sass +2 -0
  120. data/test/sass/templates/import.sass +4 -4
  121. data/test/sass/templates/importee.sass +3 -3
  122. data/test/sass/templates/line_numbers.sass +1 -1
  123. data/test/sass/templates/mixin_bork.sass +5 -0
  124. data/test/sass/templates/mixins.sass +2 -2
  125. data/test/sass/templates/nested_bork1.sass +2 -0
  126. data/test/sass/templates/nested_bork2.sass +2 -0
  127. data/test/sass/templates/nested_bork3.sass +2 -0
  128. data/test/sass/templates/nested_bork4.sass +2 -0
  129. data/test/sass/templates/nested_mixin_bork.sass +6 -0
  130. data/test/sass/templates/options.sass +2 -0
  131. data/test/sass/templates/parent_ref.sass +2 -2
  132. data/test/sass/templates/script.sass +69 -69
  133. data/test/sass/templates/scss_import.scss +10 -0
  134. data/test/sass/templates/scss_importee.scss +1 -0
  135. data/test/sass/templates/units.sass +10 -10
  136. data/test/test_helper.rb +20 -8
  137. data/vendor/fssm/LICENSE +20 -0
  138. data/vendor/fssm/README.markdown +55 -0
  139. data/vendor/fssm/Rakefile +59 -0
  140. data/vendor/fssm/VERSION.yml +5 -0
  141. data/vendor/fssm/example.rb +9 -0
  142. data/vendor/fssm/fssm.gemspec +77 -0
  143. data/vendor/fssm/lib/fssm.rb +33 -0
  144. data/vendor/fssm/lib/fssm/backends/fsevents.rb +36 -0
  145. data/vendor/fssm/lib/fssm/backends/inotify.rb +26 -0
  146. data/vendor/fssm/lib/fssm/backends/polling.rb +25 -0
  147. data/vendor/fssm/lib/fssm/backends/rubycocoa/fsevents.rb +131 -0
  148. data/vendor/fssm/lib/fssm/monitor.rb +26 -0
  149. data/vendor/fssm/lib/fssm/path.rb +91 -0
  150. data/vendor/fssm/lib/fssm/pathname.rb +502 -0
  151. data/vendor/fssm/lib/fssm/state/directory.rb +57 -0
  152. data/vendor/fssm/lib/fssm/state/file.rb +24 -0
  153. data/vendor/fssm/lib/fssm/support.rb +63 -0
  154. data/vendor/fssm/lib/fssm/tree.rb +176 -0
  155. data/vendor/fssm/profile/prof-cache.rb +40 -0
  156. data/vendor/fssm/profile/prof-fssm-pathname.html +1231 -0
  157. data/vendor/fssm/profile/prof-pathname.rb +68 -0
  158. data/vendor/fssm/profile/prof-plain-pathname.html +988 -0
  159. data/vendor/fssm/profile/prof.html +2379 -0
  160. data/vendor/fssm/spec/path_spec.rb +75 -0
  161. data/vendor/fssm/spec/root/duck/quack.txt +0 -0
  162. data/vendor/fssm/spec/root/file.css +0 -0
  163. data/vendor/fssm/spec/root/file.rb +0 -0
  164. data/vendor/fssm/spec/root/file.yml +0 -0
  165. data/vendor/fssm/spec/root/moo/cow.txt +0 -0
  166. data/vendor/fssm/spec/spec_helper.rb +14 -0
  167. metadata +94 -14
  168. data/test/sass/templates/bork.sass +0 -2
@@ -24,6 +24,6 @@ body { font: Arial; background: blue; }
24
24
 
25
25
  @import url(basic.css);
26
26
  @import url(../results/complex.css);
27
- #foo { background-color: #baf; }
27
+ #foo { background-color: #bbaaff; }
28
28
 
29
29
  nonimported { myconst: hello; otherconst: goodbye; post-mixin: here; }
@@ -1,4 +1,4 @@
1
- !preconst = "hello"
1
+ $preconst: hello
2
2
 
3
3
  =premixin
4
4
  pre-mixin: here
@@ -6,6 +6,6 @@
6
6
  @import importee, basic, basic.css, ../results/complex.css, more_partial
7
7
 
8
8
  nonimported
9
- :myconst = !preconst
10
- :otherconst = !postconst
9
+ :myconst $preconst
10
+ :otherconst $postconst
11
11
  +postmixin
@@ -5,8 +5,9 @@ require 'fileutils'
5
5
 
6
6
  class SassPluginTest < Test::Unit::TestCase
7
7
  @@templates = %w{
8
- complex script parent_ref import alt
8
+ complex script parent_ref import scss_import alt
9
9
  subdir/subdir subdir/nested_subdir/nested_subdir
10
+ options
10
11
  }
11
12
 
12
13
  def setup
@@ -19,6 +20,7 @@ class SassPluginTest < Test::Unit::TestCase
19
20
 
20
21
  def teardown
21
22
  clean_up_sassc
23
+ clear_callbacks
22
24
  FileUtils.rm_r tempfile_loc
23
25
  FileUtils.rm_r tempfile_loc(nil,"more_")
24
26
  end
@@ -48,22 +50,46 @@ class SassPluginTest < Test::Unit::TestCase
48
50
  assert_needs_update 'import'
49
51
  Sass::Plugin.update_stylesheets
50
52
  assert_stylesheet_updated 'basic'
53
+ assert_stylesheet_updated 'import'
54
+ end
55
+
56
+ def test_update_needed_when_scss_dependency_modified
57
+ touch 'scss_importee'
58
+ assert_needs_update 'import'
59
+ Sass::Plugin.update_stylesheets
60
+ assert_stylesheet_updated 'scss_importee'
61
+ assert_stylesheet_updated 'import'
62
+ end
63
+
64
+ def test_scss_update_needed_when_dependency_modified
65
+ touch 'basic'
66
+ assert_needs_update 'scss_import'
67
+ Sass::Plugin.update_stylesheets
68
+ assert_stylesheet_updated 'basic'
69
+ assert_stylesheet_updated 'scss_import'
51
70
  end
52
71
 
53
72
  def test_full_exception_handling
54
- File.delete(tempfile_loc('bork'))
73
+ File.delete(tempfile_loc('bork1'))
55
74
  Sass::Plugin.update_stylesheets
56
- File.open(tempfile_loc('bork')) do |file|
57
- assert_equal("/*\nSass::SyntaxError: Undefined variable: \"!bork\".\non line 2 of #{template_loc('bork')}\n\n1: bork\n2: :bork= !bork", file.read.split("\n")[0...6].join("\n"))
75
+ File.open(tempfile_loc('bork1')) do |file|
76
+ assert_equal(<<CSS.strip, file.read.split("\n")[0...6].join("\n"))
77
+ /*
78
+ Syntax error: Undefined variable: "$bork".
79
+ on line 2 of #{template_loc('bork1')}
80
+
81
+ 1: bork
82
+ 2: :bork $bork
83
+ CSS
58
84
  end
59
- File.delete(tempfile_loc('bork'))
85
+ File.delete(tempfile_loc('bork1'))
60
86
  end
61
87
 
62
88
  def test_nonfull_exception_handling
63
89
  old_full_exception = Sass::Plugin.options[:full_exception]
64
90
  Sass::Plugin.options[:full_exception] = false
65
91
 
66
- File.delete(tempfile_loc('bork'))
92
+ File.delete(tempfile_loc('bork1'))
67
93
  assert_raise(Sass::SyntaxError) {Sass::Plugin.update_stylesheets}
68
94
  ensure
69
95
  Sass::Plugin.options[:full_exception] = old_full_exception
@@ -122,6 +148,98 @@ class SassPluginTest < Test::Unit::TestCase
122
148
  assert !File.exists?(tempfile_loc('_partial'))
123
149
  end
124
150
 
151
+ # Callbacks
152
+
153
+ def test_updating_stylesheets_callback
154
+ # Should run even when there's nothing to update
155
+ assert_callback :updating_stylesheets, []
156
+ end
157
+
158
+ def test_updating_stylesheets_callback_with_individual_files
159
+ files = [[template_loc("basic"), tempfile_loc("basic")]]
160
+ assert_callback(:updating_stylesheets, files) {Sass::Plugin.update_stylesheets(files)}
161
+ end
162
+
163
+ def test_updating_stylesheets_callback_with_never_update
164
+ Sass::Plugin.options[:never_update] = true
165
+ assert_no_callback :updating_stylesheets
166
+ end
167
+
168
+ def test_updating_stylesheet_callback_for_updated_template
169
+ Sass::Plugin.options[:always_update] = false
170
+ touch 'basic'
171
+ assert_no_callback :updating_stylesheet, template_loc("complex"), tempfile_loc("complex") do
172
+ assert_callbacks(
173
+ [:updating_stylesheet, template_loc("basic"), tempfile_loc("basic")],
174
+ [:updating_stylesheet, template_loc("import"), tempfile_loc("import")])
175
+ end
176
+ end
177
+
178
+ def test_updating_stylesheet_callback_for_fresh_template
179
+ Sass::Plugin.options[:always_update] = false
180
+ assert_no_callback :updating_stylesheet
181
+ end
182
+
183
+ def test_updating_stylesheet_callback_for_error_template
184
+ Sass::Plugin.options[:always_update] = false
185
+ touch 'bork1'
186
+ assert_no_callback :updating_stylesheet
187
+ end
188
+
189
+ def test_not_updating_stylesheet_callback_for_fresh_template
190
+ Sass::Plugin.options[:always_update] = false
191
+ assert_callback :not_updating_stylesheet, template_loc("basic"), tempfile_loc("basic")
192
+ end
193
+
194
+ def test_not_updating_stylesheet_callback_for_updated_template
195
+ Sass::Plugin.options[:always_update] = false
196
+ assert_callback :not_updating_stylesheet, template_loc("complex"), tempfile_loc("complex") do
197
+ assert_no_callbacks(
198
+ [:updating_stylesheet, template_loc("basic"), tempfile_loc("basic")],
199
+ [:updating_stylesheet, template_loc("import"), tempfile_loc("import")])
200
+ end
201
+ end
202
+
203
+ def test_not_updating_stylesheet_callback_with_never_update
204
+ Sass::Plugin.options[:never_update] = true
205
+ assert_no_callback :not_updating_stylesheet
206
+ end
207
+
208
+ def test_not_updating_stylesheet_callback_for_partial
209
+ Sass::Plugin.options[:always_update] = false
210
+ assert_no_callback :not_updating_stylesheet, template_loc("_partial"), tempfile_loc("_partial")
211
+ end
212
+
213
+ def test_not_updating_stylesheet_callback_for_error
214
+ Sass::Plugin.options[:always_update] = false
215
+ touch 'bork1'
216
+ assert_no_callback :not_updating_stylesheet, template_loc("bork1"), tempfile_loc("bork1")
217
+ end
218
+
219
+ def test_compilation_error_callback
220
+ Sass::Plugin.options[:always_update] = false
221
+ touch 'bork1'
222
+ assert_callback(:compilation_error,
223
+ lambda {|e| e.message == 'Undefined variable: "$bork".'},
224
+ template_loc("bork1"), tempfile_loc("bork1"))
225
+ end
226
+
227
+ def test_compilation_error_callback_for_file_access
228
+ Sass::Plugin.options[:always_update] = false
229
+ assert_callback(:compilation_error,
230
+ lambda {|e| e.is_a?(Errno::ENOENT)},
231
+ template_loc("nonexistent"), tempfile_loc("nonexistent")) do
232
+ Sass::Plugin.update_stylesheets([[template_loc("nonexistent"), tempfile_loc("nonexistent")]])
233
+ end
234
+ end
235
+
236
+ def test_creating_directory_callback
237
+ Sass::Plugin.options[:always_update] = false
238
+ dir = File.join(tempfile_loc, "subdir", "nested_subdir")
239
+ FileUtils.rm_r dir
240
+ assert_callback :creating_directory, dir
241
+ end
242
+
125
243
  ## Regression
126
244
 
127
245
  def test_cached_dependencies_update
@@ -170,13 +288,65 @@ class SassPluginTest < Test::Unit::TestCase
170
288
  end
171
289
  end
172
290
 
291
+ def assert_callback(name, *expected_args)
292
+ run = false
293
+ Sass::Plugin.send("on_#{name}") do |*args|
294
+ run ||= expected_args.zip(args).all? do |ea, a|
295
+ ea.respond_to?(:call) ? ea.call(a) : ea == a
296
+ end
297
+ end
298
+
299
+ if block_given?
300
+ yield
301
+ else
302
+ Sass::Plugin.update_stylesheets
303
+ end
304
+
305
+ assert run, "Expected #{name} callback to be run with arguments:\n #{expected_args.inspect}"
306
+ end
307
+
308
+ def assert_no_callback(name, *unexpected_args)
309
+ Sass::Plugin.send("on_#{name}") do |*a|
310
+ next unless unexpected_args.empty? || a == unexpected_args
311
+
312
+ msg = "Expected #{name} callback not to be run"
313
+ if !unexpected_args.empty?
314
+ msg << " with arguments #{unexpected_args.inspect}"
315
+ elsif !a.empty?
316
+ msg << ",\n was run with arguments #{a.inspect}"
317
+ end
318
+
319
+ flunk msg
320
+ end
321
+
322
+ if block_given?
323
+ yield
324
+ else
325
+ Sass::Plugin.update_stylesheets
326
+ end
327
+ end
328
+
329
+ def assert_callbacks(*args)
330
+ return Sass::Plugin.update_stylesheets if args.empty?
331
+ assert_callback(*args.pop) {assert_callbacks(*args)}
332
+ end
333
+
334
+ def assert_no_callbacks(*args)
335
+ return Sass::Plugin.update_stylesheets if args.empty?
336
+ assert_no_callback(*args.pop) {assert_no_callbacks(*args)}
337
+ end
338
+
339
+ def clear_callbacks
340
+ Sass::Plugin.instance_variable_set('@_sass_callbacks', {})
341
+ end
342
+
173
343
  def assert_needs_update(name)
174
- assert(Sass::Plugin.stylesheet_needs_update?(name, template_loc, tempfile_loc),
344
+ assert(Sass::Plugin.stylesheet_needs_update?(tempfile_loc(name), template_loc(name)),
175
345
  "Expected #{template_loc(name)} to need an update.")
176
346
  end
177
347
 
178
348
  def assert_doesnt_need_update(name)
179
- assert(!Sass::Plugin.stylesheet_needs_update?(name, template_loc, tempfile_loc),
349
+ assert(!Sass::Plugin.stylesheet_needs_update?(tempfile_loc(name), template_loc(name)),
180
350
  "Expected #{template_loc(name)} not to need an update.")
181
351
  end
182
352
 
@@ -185,12 +355,15 @@ class SassPluginTest < Test::Unit::TestCase
185
355
  end
186
356
 
187
357
  def reset_mtimes
188
- Dir["{#{template_loc},#{tempfile_loc}}/**/*.{css,sass}"].each {|f| File.utime(Time.now, Time.now - 1, f)}
358
+ atime = Time.now
359
+ mtime = Time.now - 5
360
+ Dir["{#{template_loc},#{tempfile_loc}}/**/*.{css,sass,scss}"].each {|f| File.utime(atime, mtime, f)}
189
361
  end
190
362
 
191
363
  def template_loc(name = nil, prefix = nil)
192
364
  if name
193
- absolutize "#{prefix}templates/#{name}.sass"
365
+ scss = absolutize "#{prefix}templates/#{name}.scss"
366
+ File.exists?(scss) ? scss : absolutize("#{prefix}templates/#{name}.sass")
194
367
  else
195
368
  absolutize "#{prefix}templates"
196
369
  end
@@ -223,6 +396,7 @@ class SassPluginTest < Test::Unit::TestCase
223
396
  :style => :compact,
224
397
  :load_paths => [result_loc],
225
398
  :always_update => true,
399
+ :never_update => false,
226
400
  }.merge(overrides)
227
401
  end
228
402
  end
@@ -1,4 +1,4 @@
1
- #main { width: 15em; color: #0000ff; }
1
+ #main { width: 15em; color: blue; }
2
2
  #main p { border-style: dotted; /* Nested comment More nested stuff */ border-width: 2px; }
3
3
  #main .cool { width: 100px; }
4
4
 
@@ -1,10 +1,10 @@
1
- body { margin: 0; font: 0.85em "Lucida Grande", "Trebuchet MS", Verdana, sans-serif; color: #fff; background: url(/images/global_bg.gif); }
1
+ body { margin: 0; font: 0.85em "Lucida Grande", "Trebuchet MS", Verdana, sans-serif; color: white; background: url(/images/global_bg.gif); }
2
2
 
3
3
  #page { width: 900px; margin: 0 auto; background: #440008; border-top-width: 5px; border-top-style: solid; border-top-color: #ff8500; }
4
4
 
5
5
  #header { height: 75px; padding: 0; }
6
6
  #header h1 { float: left; width: 274px; height: 75px; margin: 0; background-image: url(/images/global_logo.gif); /* Crazy nested comment */ background-repeat: no-repeat; text-indent: -9999px; }
7
- #header .status { float: right; padding-top: .5em; padding-left: .5em; padding-right: .5em; padding-bottom: 0; }
7
+ #header .status { float: right; padding-top: 0.5em; padding-left: 0.5em; padding-right: 0.5em; padding-bottom: 0; }
8
8
  #header .status p { float: left; margin-top: 0; margin-right: 0.5em; margin-bottom: 0; margin-left: 0; }
9
9
  #header .status ul { float: left; margin: 0; padding: 0; }
10
10
  #header .status li { list-style-type: none; display: inline; margin: 0 5px; }
@@ -16,9 +16,9 @@ body { margin: 0; font: 0.85em "Lucida Grande", "Trebuchet MS", Verdana, sans-se
16
16
 
17
17
  #menu { clear: both; text-align: right; height: 20px; border-bottom: 5px solid #006b95; background: #00a4e4; }
18
18
  #menu .contests ul { margin: 0 5px 0 0; padding: 0; }
19
- #menu .contests ul li { list-style-type: none; margin: 0 5px; padding: 5px 5px 0 5px; display: inline; font-size: 1.1em; color: #fff; background: #00a4e4; }
19
+ #menu .contests ul li { list-style-type: none; margin: 0 5px; padding: 5px 5px 0 5px; display: inline; font-size: 1.1em; color: white; background: #00a4e4; }
20
20
  #menu .contests ul li / This rule isn't a comment! { red: green; }
21
- #menu .contests a:link, #menu .contests a:visited { color: #fff; text-decoration: none; font-weight: bold; }
21
+ #menu .contests a:link, #menu .contests a:visited { color: white; text-decoration: none; font-weight: bold; }
22
22
  #menu .contests a:hover { text-decoration: underline; }
23
23
 
24
24
  #content { clear: both; }
@@ -82,6 +82,6 @@ body { margin: 0; font: 0.85em "Lucida Grande", "Trebuchet MS", Verdana, sans-se
82
82
 
83
83
  img { border: none; }
84
84
 
85
- button.short { width: 60px; height: 22px; padding: 0 0 2px 0; color: #fff; border: none; background: url(/images/btn_short.gif) no-repeat; }
85
+ button.short { width: 60px; height: 22px; padding: 0 0 2px 0; color: white; border: none; background: url(/images/btn_short.gif) no-repeat; }
86
86
 
87
87
  table { border-collapse: collapse; }
@@ -1 +1 @@
1
- #main{width:15em;color:#0000ff}#main p{border-style:dotted;border-width:2px}#main .cool{width:100px}#left{font-size:2em;font-weight:bold;float:left}
1
+ #main{width:15em;color:blue}#main p{border-style:dotted;border-width:2px}#main .cool{width:100px}#left{font-size:2em;font-weight:bold;float:left}
@@ -1,6 +1,6 @@
1
1
  #main {
2
2
  width: 15em;
3
- color: #0000ff;
3
+ color: blue;
4
4
  }
5
5
  #main p {
6
6
  border-style: dotted;
@@ -12,6 +12,8 @@ body { font: Arial; background: blue; }
12
12
 
13
13
  midrule { inthe: middle; }
14
14
 
15
+ scss { imported: yes; }
16
+
15
17
  body { font: Arial; background: blue; }
16
18
 
17
19
  #page { width: 700px; height: 100; }
@@ -24,6 +26,6 @@ body { font: Arial; background: blue; }
24
26
 
25
27
  @import url(basic.css);
26
28
  @import url(../results/complex.css);
27
- #foo { background-color: #baf; }
29
+ #foo { background-color: #bbaaff; }
28
30
 
29
31
  nonimported { myconst: hello; otherconst: goodbye; post-mixin: here; }
@@ -1,12 +1,12 @@
1
1
  #main {
2
2
  width: 15em;
3
- color: #0000ff;
3
+ color: blue;
4
4
  }
5
5
  #main p {
6
6
  border-top-width: 2px;
7
7
  border-top-color: #ffcc00;
8
8
  border-left-width: 1px;
9
- border-left-color: #000;
9
+ border-left-color: black;
10
10
  -moz-border-radius: 10px;
11
11
  border-style: dotted;
12
12
  border-width: 2px;
@@ -19,7 +19,7 @@
19
19
  border-top-width: 2px;
20
20
  border-top-color: #ffcc00;
21
21
  border-left-width: 1px;
22
- border-left-color: #000;
22
+ border-left-color: black;
23
23
  -moz-border-radius: 10px;
24
24
  font-size: 2em;
25
25
  font-weight: bold;
@@ -30,9 +30,9 @@
30
30
  border-top-width: 2px;
31
31
  border-top-color: #ffcc00;
32
32
  border-left-width: 1px;
33
- border-left-color: #000;
33
+ border-left-color: black;
34
34
  -moz-border-radius: 10px;
35
- color: #f00;
35
+ color: red;
36
36
  font-size: 20px;
37
37
  float: right;
38
38
  }
@@ -41,12 +41,12 @@
41
41
  border-top-width: 2px;
42
42
  border-top-color: #ffcc00;
43
43
  border-left-width: 1px;
44
- border-left-color: #000;
44
+ border-left-color: black;
45
45
  -moz-border-radius: 10px;
46
46
  }
47
47
 
48
48
  .complex {
49
- color: #f00;
49
+ color: red;
50
50
  font-size: 20px;
51
51
  text-decoration: none;
52
52
  }
@@ -59,12 +59,12 @@
59
59
  }
60
60
  * html .complex {
61
61
  height: 1px;
62
- color: #f00;
62
+ color: red;
63
63
  font-size: 20px;
64
64
  }
65
65
 
66
66
  .more-complex {
67
- color: #f00;
67
+ color: red;
68
68
  font-size: 20px;
69
69
  text-decoration: none;
70
70
  display: inline;
@@ -80,16 +80,16 @@
80
80
  }
81
81
  * html .more-complex {
82
82
  height: 1px;
83
- color: #f00;
83
+ color: red;
84
84
  font-size: 20px;
85
85
  }
86
86
  .more-complex a:hover {
87
87
  text-decoration: underline;
88
- color: #f00;
88
+ color: red;
89
89
  font-size: 20px;
90
90
  border-top-width: 2px;
91
91
  border-top-color: #ffcc00;
92
92
  border-left-width: 1px;
93
- border-left-color: #000;
93
+ border-left-color: black;
94
94
  -moz-border-radius: 10px;
95
95
  }
@@ -1,6 +1,6 @@
1
1
  #main {
2
2
  width: 15em;
3
- color: #0000ff; }
3
+ color: blue; }
4
4
  #main p {
5
5
  border-style: dotted;
6
6
  /* Nested comment
@@ -0,0 +1 @@
1
+ foo { style: compact; }