hamlit 1.5.6 → 1.5.7
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +4 -0
- data/lib/hamlit/parsers/tag.rb +3 -1
- data/lib/hamlit/version.rb +1 -1
- data/spec/hamlit/engine/tag_spec.rb +9 -0
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: bd08607e661773fdb5b3615f58c436b3efceea82
|
4
|
+
data.tar.gz: 935a17fc15a78de1d6ca821104fa8d3f74f1b54c
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: ca7571512c56d3ff44304efd1c30135344aed980dfb26395d23006068f76c35ae29ae19bc4533ec3644712a39bd03ad5b088735f325f9a01745f3808e40152e2
|
7
|
+
data.tar.gz: 26145af5ca66444899ac3498c460e1695a6ee280f802fc794664edac648f5bc8afd242d16ca3e40c95bb56d76128b351e23dc43d7a4c5c3bde805108aee5157c
|
data/CHANGELOG.md
CHANGED
data/lib/hamlit/parsers/tag.rb
CHANGED
@@ -25,7 +25,9 @@ module Hamlit
|
|
25
25
|
ast = [:html, :tag, tag, attrs]
|
26
26
|
inner_removal = parse_whitespace_removal(scanner)
|
27
27
|
|
28
|
-
|
28
|
+
if scanner.match?(/=/)
|
29
|
+
return ast << parse_script(scanner)
|
30
|
+
elsif !has_block?
|
29
31
|
return ast if scanner.scan(/\//)
|
30
32
|
return ast << parse_line(scanner, inline: true)
|
31
33
|
end
|
data/lib/hamlit/version.rb
CHANGED
@@ -8,6 +8,15 @@ describe Hamlit::Engine do
|
|
8
8
|
HTML
|
9
9
|
end
|
10
10
|
|
11
|
+
it 'accepts multi-line =' do
|
12
|
+
assert_render(<<-HAML, <<-HTML)
|
13
|
+
%span= 'hello'.gsub('hell',
|
14
|
+
'')
|
15
|
+
HAML
|
16
|
+
<span>o</span>
|
17
|
+
HTML
|
18
|
+
end
|
19
|
+
|
11
20
|
it 'renders multi-line tag' do
|
12
21
|
assert_render(<<-HAML, <<-HTML)
|
13
22
|
%span
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: hamlit
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.5.
|
4
|
+
version: 1.5.7
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Takashi Kokubun
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2015-06-
|
11
|
+
date: 2015-06-08 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: escape_utils
|