constructor-pages 0.2.11 → 0.2.12
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -11,5 +11,10 @@ module ConstructorPages
|
|
|
11
11
|
def templates
|
|
12
12
|
Template.all.map{|t| ["#{'--'*t.level} #{t.name}", t.id]}
|
|
13
13
|
end
|
|
14
|
+
|
|
15
|
+
def image_tag_with_at2x(name_at_1x, options={})
|
|
16
|
+
name_at_2x = name_at_1x.gsub(%r{\.\w+$}, '@2x\0')
|
|
17
|
+
image_tag(name_at_1x, options.merge("data-at2x" => asset_path(name_at_2x)))
|
|
18
|
+
end
|
|
14
19
|
end
|
|
15
20
|
end
|
data/constructor-pages.gemspec
CHANGED