plate-lang 0.1.1 → 0.1.2
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +1 -1
- data/lib/plate/compiler.rb +10 -3
- data/lib/plate/version.rb +1 -1
- 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: 767361b4883929be281eff1843941fcc0022f029
|
4
|
+
data.tar.gz: dc17fb291ee7cca087d139e9acfe55977a3f6fad
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: aa64633e6166a8682110458a02b0c828747ef02e87092743f745fd2f1cc7a4e5e7e716e2fc68c0c145897e47dc2d070dc275177207eecb8976381990b7bc7c93
|
7
|
+
data.tar.gz: 95f0281a632bc65882b4b497620e169dba369fc067103fc7520110ed749396cdec13c17c6ea7b8cfb8081a9affbd8ce0f8a098f1bd88a0a576ec64640a697925
|
data/README.md
CHANGED
data/lib/plate/compiler.rb
CHANGED
@@ -82,11 +82,16 @@ module Plate
|
|
82
82
|
when 'blank'
|
83
83
|
'target="_blank"'
|
84
84
|
when /\Abtn/
|
85
|
-
c = '
|
85
|
+
c = 'btn'
|
86
|
+
|
87
|
+
c << ' btn-primary' if value =~ /\-primary/
|
88
|
+
c << ' btn-default' if c == 'btn'
|
89
|
+
|
86
90
|
c << ' btn-lg' if value =~ /\-lg/
|
87
91
|
c << ' btn-sm' if value =~ /\-sm/
|
88
92
|
c << ' btn-block' if value =~ /\-block/
|
89
|
-
|
93
|
+
|
94
|
+
"class=\"#{c}\""
|
90
95
|
when /spin(\-\d+\.*\d*)?/
|
91
96
|
s = value.gsub(/spin\-?/, '')
|
92
97
|
s = 1.5 if s.empty?
|
@@ -183,8 +188,10 @@ module Plate
|
|
183
188
|
k + ' btn-default'
|
184
189
|
when 'center'
|
185
190
|
"text-#{k}"
|
186
|
-
when /\A\d
|
191
|
+
when /\A\d+\z/
|
187
192
|
"col-sm-#{k}"
|
193
|
+
when /\Aoffset\-(\d+)\z/
|
194
|
+
"col-sm-offset-#{$1}"
|
188
195
|
else
|
189
196
|
k
|
190
197
|
end
|
data/lib/plate/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: plate-lang
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.1.
|
4
|
+
version: 0.1.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- tnantoka
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2015-08-
|
11
|
+
date: 2015-08-06 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: thor
|