haml-edge 2.3.242 → 2.3.243

Sign up to get free protection for your applications and to get access to all the features.
data/EDGE_GEM_VERSION CHANGED
@@ -1 +1 @@
1
- 2.3.242
1
+ 2.3.243
data/VERSION CHANGED
@@ -1 +1 @@
1
- 2.3.242
1
+ 2.3.243
@@ -41,23 +41,8 @@ module Sass::Script
41
41
 
42
42
  # @see Node#to_s
43
43
  def to_s(opts = {})
44
- to_sass(opts)
45
- end
46
-
47
- # @param opts [{Symbol => Object}]
48
- # `opts[:type]` -- The type of string to render this as.
49
- # `:string`s have double quotes, `:identifier`s do not.
50
- # Defaults to `:identifier`.
51
- # @see Node#to_sass
52
- def to_sass(opts = {})
53
- type = opts[:type] || self.type
54
- if type == :identifier
55
- if context == :equals && self.value !~ Sass::SCSS::RX::URI &&
56
- Sass::SCSS::RX.escape_ident(self.value).include?(?\\)
57
- return "unquote(#{Sass::Script::String.new(self.value, :string).to_sass})"
58
- elsif context == :equals && self.value.size == 0
59
- return %q{""}
60
- end
44
+ if self.type == :identifier
45
+ return %q{""} if context == :equals && self.value.size == 0
61
46
  return self.value.gsub("\n", " ")
62
47
  end
63
48
 
@@ -67,5 +52,16 @@ module Sass::Script
67
52
  return "'#{value}'" unless value.include?("'")
68
53
  "\"#{value.gsub('"', "\\\"")}\"" #'
69
54
  end
55
+
56
+ # @see Node#to_sass
57
+ def to_sass(opts = {})
58
+ if self.type == :identifier && context == :equals &&
59
+ self.value !~ Sass::SCSS::RX::URI &&
60
+ Sass::SCSS::RX.escape_ident(self.value).include?(?\\)
61
+ return "unquote(#{Sass::Script::String.new(self.value, :string).to_sass})"
62
+ else
63
+ return to_s
64
+ end
65
+ end
70
66
  end
71
67
  end
@@ -1608,13 +1608,15 @@ foo {
1608
1608
  a: foo;
1609
1609
  b: bar;
1610
1610
  c: foo bar;
1611
- d: foo, bar; }
1611
+ d: foo, bar baz;
1612
+ e: foo bar, bar; }
1612
1613
  CSS
1613
1614
  foo
1614
1615
  a= "foo"
1615
1616
  b= bar
1616
1617
  c= "foo" bar
1617
- d= foo, "bar"
1618
+ d= foo, "bar baz"
1619
+ e= "foo bar", bar
1618
1620
  SASS
1619
1621
  end
1620
1622
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: haml-edge
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.3.242
4
+ version: 2.3.243
5
5
  platform: ruby
6
6
  authors:
7
7
  - Nathan Weizenbaum