ir_helper 0.2.0

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml ADDED
@@ -0,0 +1,7 @@
1
+ ---
2
+ SHA1:
3
+ metadata.gz: 5e10d8fb83d7346b07073b7fd54f27c48e769b70
4
+ data.tar.gz: 393df95bbd2b9fe1e2740a7b8cbe91a3fb19009b
5
+ SHA512:
6
+ metadata.gz: e2548c6e1739347dc163191011b22692fc5233fd9e9df51b15c3e057c7b1025402a176740dc86aaf1ab8937598b8548ad1b618e8df7c902a07ebf20cb9e7ce7c
7
+ data.tar.gz: e4e9767006f1b435297b12bd588a37dd8eeafb5ad39e218ffae0ba130ef0016a793f4097d0a2f8d8134415ddee92e93ec2097c3546ad93aeabd63d335614fadc
data/LICENSE.txt ADDED
@@ -0,0 +1,22 @@
1
+ Copyright (c) 2014 James Nicol
2
+
3
+ MIT License
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining
6
+ a copy of this software and associated documentation files (the
7
+ "Software"), to deal in the Software without restriction, including
8
+ without limitation the rights to use, copy, modify, merge, publish,
9
+ distribute, sublicense, and/or sell copies of the Software, and to
10
+ permit persons to whom the Software is furnished to do so, subject to
11
+ the following conditions:
12
+
13
+ The above copyright notice and this permission notice shall be
14
+ included in all copies or substantial portions of the Software.
15
+
16
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
17
+ EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
18
+ MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
19
+ NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
20
+ LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
21
+ OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
22
+ WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
data/README.md ADDED
@@ -0,0 +1,111 @@
1
+ # IrHelper
2
+
3
+ This gem includes helpers to build the appropriate URLs for images served via an [image-resizer](https://github.com/jimmynicol/image-resizer) instance.
4
+
5
+ ## Installation
6
+
7
+ Add this line to your application's Gemfile:
8
+
9
+ gem 'ir-helper'
10
+
11
+ And then execute:
12
+
13
+ $ bundle
14
+
15
+ Or install it yourself as:
16
+
17
+ $ gem install ir-helper
18
+
19
+ ## Configuration
20
+ Configuring this gem is done via:
21
+
22
+ IrHelper.configure do |config|
23
+ # add your configuration here...
24
+ end
25
+
26
+ For a rails project this is best done via an [initializer](http://guides.rubyonrails.org/configuring.html).
27
+
28
+ The available config options are:
29
+
30
+ ### CDN
31
+ This is a required setting.
32
+
33
+ config.cdn = 'https://my.cdn.com'
34
+
35
+
36
+ ### Modifiers
37
+ This gem comes with all the available modifiers that are supported natively by `image-resizer` but also allows you add your own modifier strings if you have built custom options into your own implementation.
38
+
39
+ # config.add_modifier(key, alias='', values=[])
40
+ config.add_modifiers(:x, :xtra, ['one', 'two'])
41
+
42
+ ### Sources
43
+ As with modifiers you can add more external source options. Natively Facebook, Twitter, Youtube and Vimeo are supported but should you chose to add another to that list you can configure the gem with them
44
+
45
+ # config.add_source(name, option)
46
+ config.add_source(:myspace, :ms_id)
47
+
48
+ ### Ruby method aliases
49
+ If you need for whatever reason to alias the helper methods provided you can do that via config aswell.
50
+
51
+ config.add_alias :ir_image_tag, :something_else
52
+
53
+ ### Javascript aliases
54
+ You can also override any of the JS method names, including the global object name.
55
+
56
+ config.add_js_alias :js_class, 'MyAwesomeResizer'
57
+ config.add_js_alias :js_image_tag, 'something'
58
+
59
+ ## Usage
60
+
61
+ The functionality in this gem has two parts, a ruby view helper and a javascript helper.
62
+
63
+ ### Ruby View Helper
64
+
65
+ You can generate an image tag in the same way the regular [helper](http://guides.rubyonrails.org/layouts_and_rendering.html#asset-tag-helpers) does, just with adding a valid set of modifiers
66
+
67
+ <div class="content">
68
+ <%= ir_image_tag('https://s3.amazonaws.com/sample.bucket/path/to/image.jpg', h:200, w:300) %>
69
+ <%= ir_image_tag(fb_uid: 'missnine', s:100) %>
70
+ </div>
71
+
72
+ You can generate a background image string
73
+
74
+ <div style="<%= ir_background('https://s3.amazonaws.com/sample.bucket/path/to/image.jpg', h:200, w:300) %>"></div>
75
+
76
+ Or just return the url as needed
77
+
78
+ <div class="content">
79
+ <%= ir_url('https://s3.amazonaws.com/sample.bucket/path/to/image.jpg', h:200, w:300) %>
80
+ </div>
81
+
82
+ ### Javascript Helper
83
+
84
+ The Javascript helper is generated from the config data as an `.erb` file on load. So all of the new modifiers or sources added will be reflected, as well as any aliases set.
85
+
86
+ The JS helper (`image_resizer.js`) is either attached as a global, or can be loaded via AMD or CommonJS if you are using those techniques. It has the same helper methods as the ruby helper.
87
+
88
+ <script>
89
+ var imgUrl = 'https://s3.amazonaws.com/sample.bucket/path/to/image.jpg';
90
+ $('#image-tag').append(IR.irImageTag(imgUrl, {s:200}));
91
+ $('#image-bg').attr('style', IR.irBackground(imgUrl, {s:200}));
92
+ $('#image-url').text(IR.irImageTag(imgUrl, {s:200}));
93
+ </script>
94
+ <div id="image-tag"></div>
95
+ <div id="image-bg"></div>
96
+ <div id="image-url"></div>
97
+
98
+ ## Tests
99
+ The ruby helpers are tested with RSpec and they can be run with either:
100
+
101
+ $ guard
102
+ $ rspec
103
+
104
+
105
+ ## Contributing
106
+
107
+ 1. Fork it
108
+ 2. Create your feature branch (`git checkout -b my-new-feature`)
109
+ 3. Commit your changes (`git commit -am 'Add some feature'`)
110
+ 4. Push to the branch (`git push origin my-new-feature`)
111
+ 5. Create new Pull Request
@@ -0,0 +1,201 @@
1
+ /**
2
+ Javascript helper for building `image-resizer` url endpoints
3
+ - this file is partially built via the parent ruby process to include the
4
+ available modifiers and custom class/method names.
5
+ */
6
+ (function(root, factory) {
7
+ 'use strict';
8
+
9
+ // AMD: import Backbone and underscore into the factory
10
+ if (typeof define === 'function' && define.amd) {
11
+ define([], function(){
12
+ return factory(root);
13
+ });
14
+
15
+ // CommonJS: for Node.js or Browserify
16
+ } else if (typeof exports !== 'undefined') {
17
+ module.exports = factory(root);
18
+
19
+ // Finally, as a browser global.
20
+ } else {
21
+ root.<%= IrHelper.js_class %> = factory(root);
22
+ }
23
+
24
+ }(this, function(root){
25
+ 'use strict';
26
+
27
+ // Private methods
28
+ function parseArgs(){
29
+ var source, modifiers;
30
+ source = typeof arguments[0] === 'string' ? arguments[0] : null;
31
+ if (source){
32
+ modifiers = arguments[1];
33
+ } else {
34
+ modifiers = arguments[0];
35
+ }
36
+ return { source: source, modifiers: modifiers };
37
+ };
38
+
39
+ function generateEndpoint(source, modifiers){
40
+ var uri, cdn, mods, path;
41
+
42
+ uri = source ? URI(source) : null;
43
+ cdn = IR.CDN.replace(/\/$/, '');
44
+ mods = modStr(uri, modifiers);
45
+ path = buildPath(uri, modifiers);
46
+
47
+ return cdn + mods + path;
48
+ };
49
+
50
+ function modSet(key){
51
+ var k, v;
52
+ for (k in IR.modifiers){
53
+ v = IR.modifiers[k];
54
+ if (k === key || v.alias === key){
55
+ return v;
56
+ }
57
+ }
58
+ return null;
59
+ };
60
+
61
+ function sourceOption(key){
62
+ var mods = IR.modifiers.e.values
63
+ for (var k in mods){
64
+ if (key === mods[k]){
65
+ return [k, mods[k]];
66
+ }
67
+ }
68
+ return null;
69
+ };
70
+
71
+ function modStr(uri, modifiers){
72
+ var modArr = [];
73
+ if (modifiers){
74
+ modArr = buildModArr(modifiers);
75
+ }
76
+ if (uri && urlDomain(uri.hostname) === 'facebook'){
77
+ modArr.push('efacebook');
78
+ }
79
+ return modArr.length > 0 ? '/' + modArr.join('-') : '';
80
+ };
81
+
82
+ function buildModArr(modifiers){
83
+ var modArr, k, v, mSet, src;
84
+
85
+ modArr = [];
86
+ for (k in modifiers){
87
+ v = modifiers[k];
88
+ mSet = modSet(k);
89
+ src = sourceOption(k);
90
+ if (mSet){
91
+ if (mSet.values){
92
+ if (mSet.values[v]){
93
+ modArr.push(k + v);
94
+ }
95
+ } else {
96
+ modArr.push(k + v);
97
+ }
98
+ } else if (src) {
99
+ modArr.push('e' + src[0]);
100
+ }
101
+ }
102
+
103
+ return modArr;
104
+ };
105
+
106
+ function buildPath(uri, modifiers){
107
+ if(uri){
108
+ switch(urlDomain(uri.hostname)){
109
+ case 's3':
110
+ return s3Object(uri);
111
+ break;
112
+ case 'facebook':
113
+ return fbUid(uri);
114
+ break;
115
+ default:
116
+ ''
117
+ }
118
+ } else {
119
+ for (var k in modifiers){
120
+ if (sourceOption(k)){
121
+ return '/' + modifiers[k] + '.jpg';
122
+ }
123
+ }
124
+ }
125
+ };
126
+
127
+ function urlDomain(host){
128
+ var domain = 'other';
129
+ if (/s3.amazonaws.com/i.test(host)){
130
+ domain = 's3';
131
+ }
132
+ if (/facebook.com/i.test(host)){
133
+ domain = 'facebook';
134
+ }
135
+ return domain;
136
+ };
137
+
138
+ function s3Object(uri){
139
+ if (uri.hostname === 's3.amazonaws.com'){
140
+ return '/' + uri.pathname.split('/').slice(2).join('/');
141
+ } else {
142
+ return uri.pathname;
143
+ }
144
+ };
145
+
146
+ function URI(url){
147
+ var parser = document.createElement('a');
148
+ parser.href = url;
149
+ return parser;
150
+ };
151
+
152
+ function fbUid(uri){
153
+ return uri.pathname.split('/')[1];
154
+ };
155
+
156
+ function altTag(url){
157
+ return url.split('/').pop().split('.')[0];
158
+ };
159
+
160
+ function IR(){}
161
+
162
+ // Public methods
163
+ IR.irImageTag = function(){
164
+ var args = parseArgs.apply(this, arguments),
165
+ url = generateEndpoint(args.source, args.modifiers),
166
+ alt = altTag(url);
167
+
168
+ return '<img alt="' + alt + '" src="' + url + '" />';
169
+ };
170
+
171
+ IR.irBackground = function(){
172
+ var args = parseArgs.apply(this, arguments),
173
+ url = generateEndpoint(args.source, args.modifiers);
174
+ return 'background-image:url(' + url + ')';
175
+ };
176
+
177
+ IR.irUrl = function(){
178
+ var args = parseArgs.apply(this, arguments);
179
+ return generateEndpoint(args.source, args.modifiers);
180
+ };
181
+
182
+ // Public constants
183
+ IR.modifiers = <%= IrHelper.modifiers.to_json %>;
184
+
185
+ IR.CDN = <%= IrHelper.cdn.to_json %>;
186
+
187
+ IR.VERSION = <%= IrHelper::VERSION.to_json %>;
188
+
189
+ // Alias any methods that have been listed in the config
190
+ <% unless IrHelper.js_image_tag.nil? %>
191
+ IR.<%= IrHelper.js_image_tag %> = IR.irImageTag;
192
+ <% end %>
193
+ <% unless IrHelper.js_background.nil? %>
194
+ IR.<%= IrHelper.js_background %> = IR.irBackground;
195
+ <% end %>
196
+ <% unless IrHelper.js_url.nil? %>
197
+ IR.<%= IrHelper.js_url %> = IR.irUrl;
198
+ <% end %>
199
+
200
+ return IR;
201
+ }));
@@ -0,0 +1,12 @@
1
+ require 'ir_helper/helper'
2
+
3
+ module IrHelper
4
+ # Series of view helpers building url strings for image-resizer endpoints
5
+ module ViewHelper
6
+ def self.included(base)
7
+ base.class_eval do
8
+ include ::IrHelper::Helper
9
+ end
10
+ end
11
+ end
12
+ end
@@ -0,0 +1,7 @@
1
+ module IrHelper
2
+ class Engine < ::Rails::Engine
3
+ # initializer 'image-resizer-rails.assets.precompile' do |app|
4
+ # app.config.assets.precompile << 'image_resizer'
5
+ # end
6
+ end
7
+ end
@@ -0,0 +1,149 @@
1
+ require 'uri'
2
+
3
+ module IrHelper
4
+ # Series of view helpers building url strings for image-resizer endpoints
5
+ module Helper
6
+ def ir_image_tag(*args)
7
+ src = generate_ir_endpoint(args)
8
+ return nil if src.nil?
9
+ if respond_to?(:image_tag)
10
+ image_tag src
11
+ else
12
+ "<img src='#{src}' />"
13
+ end
14
+ end
15
+
16
+ def ir_background(*args)
17
+ url = generate_ir_endpoint(args)
18
+ url ? "background-image:url(#{url})" : nil
19
+ end
20
+
21
+ def ir_url(*args)
22
+ generate_ir_endpoint(args)
23
+ end
24
+
25
+ private
26
+
27
+ def parse_arguments(args)
28
+ if args[0].is_a?(String) || args[0].nil?
29
+ [args[0], args[1..-1]]
30
+ else
31
+ [nil, args]
32
+ end
33
+ end
34
+
35
+ def cdn
36
+ ::IrHelper.cdn
37
+ end
38
+
39
+ def self.img_tag_name
40
+ ::IrHelper.image_tag_name
41
+ end
42
+
43
+ def mods
44
+ ::IrHelper.modifiers
45
+ end
46
+
47
+ def mod_set(key)
48
+ mods.each do |k, v|
49
+ return v if key == k || v[:alias] == key
50
+ end
51
+ nil
52
+ end
53
+
54
+ def sources
55
+ mods[:e][:values]
56
+ end
57
+
58
+ def source_option(key)
59
+ sources.each do |k, v|
60
+ return [k, v] if key == v
61
+ end
62
+ nil
63
+ end
64
+
65
+ def generate_ir_endpoint(args)
66
+ fail NoCDNException if cdn.nil?
67
+
68
+ source, modifiers = parse_arguments(args)
69
+ uri = source ? URI(source) : nil
70
+ modifier_str = mod_str(uri, modifiers)
71
+ path = build_path(uri, modifiers)
72
+
73
+ if path
74
+ "#{cdn.gsub(/\/$/, '')}#{modifier_str}#{path}"
75
+ else
76
+ nil
77
+ end
78
+ end
79
+
80
+ def mod_str(uri, modifiers)
81
+ mod_arr = []
82
+ unless modifiers.nil? || modifiers[0].nil?
83
+ mod_arr = build_mod_arr(modifiers)
84
+ end
85
+ mod_arr << 'efacebook' if uri && url_domain(uri.host) == :facebook
86
+ mod_arr.compact
87
+ mod_arr.length > 0 ? "/#{mod_arr.join('-')}" : ''
88
+ end
89
+
90
+ def build_mod_arr(modifiers)
91
+ modifiers[0].map do |k, v|
92
+ mset = mod_set(k)
93
+ src = source_option(k)
94
+ if mset
95
+ if mset.include? :values
96
+ mset[:values].include?(v) ? "#{k}#{v}" : nil
97
+ else
98
+ "#{k}#{v}"
99
+ end
100
+ elsif src
101
+ "e#{src.first}"
102
+ else
103
+ nil
104
+ end
105
+ end
106
+ end
107
+
108
+ def build_path(uri, modifiers)
109
+ if uri
110
+ case url_domain(uri.host)
111
+ when :s3
112
+ s3_object uri
113
+ when :facebook
114
+ "/#{fb_uid(uri)}.jpg"
115
+ else
116
+ end
117
+ else
118
+ modifiers[0].each do |k, v|
119
+ return "/#{v}.jpg" if source_option(k)
120
+ end
121
+ nil
122
+ end
123
+ end
124
+
125
+ def url_domain(host)
126
+ return :s3 if /s3.amazonaws.com/i =~ host
127
+ return :facebook if /facebook.com/i =~ host
128
+ :other
129
+ end
130
+
131
+ def s3_object(uri)
132
+ # test to see which type of s3 url we have
133
+ if uri.host == 's3.amazonaws.com'
134
+ # this version has the bucket at the first part of the path
135
+ "/#{uri.path.split('/')[2..-1].join('/')}"
136
+ else
137
+ # this version has the bucket included in the host
138
+ uri.path
139
+ end
140
+ end
141
+
142
+ def fb_uid(uri)
143
+ uri.path.split('/')[1]
144
+ end
145
+ end
146
+
147
+ class NoCDNException < Exception; end
148
+ class NotS3SourceException < Exception; end
149
+ end
@@ -0,0 +1,3 @@
1
+ module IrHelper
2
+ VERSION = '0.2.0'
3
+ end
data/lib/ir_helper.rb ADDED
@@ -0,0 +1,92 @@
1
+ require 'ir_helper/version'
2
+ require 'ir_helper/helper'
3
+ require 'ir_helper/engine' if defined?(Rails)
4
+
5
+ module IrHelper
6
+
7
+ class << self
8
+ attr_accessor :cdn
9
+ attr_reader :js_class, :js_image_tag, :js_background, :js_url
10
+
11
+ def configure(&block)
12
+ yield self
13
+ end
14
+
15
+ def reset_config
16
+ @cdn = nil
17
+ @ir_image_tag = nil
18
+ @ir_background = nil
19
+ @ir_url = nil
20
+ @js_class = 'ImageResizer'
21
+ @js_image_tag = nil
22
+ @js_background = nil
23
+ @js_url = nil
24
+ @modifiers = default_modifiers
25
+ end
26
+
27
+ def modifiers
28
+ @modifiers ||= default_modifiers
29
+ end
30
+
31
+ def add_modifier(key, img_tag = '', values = [])
32
+ @modifiers[key.to_sym] = { alias: img_tag, values: values }
33
+ end
34
+
35
+ def add_source(name, option)
36
+ @modifiers[:e][:values][name.to_sym] = option.to_sym
37
+ end
38
+
39
+ def js_class
40
+ @js_class ||= 'IR'
41
+ end
42
+
43
+ def add_alias(type, name)
44
+ Helper.class_eval do |base|
45
+ base.send(:alias_method, name.to_sym, type.to_sym)
46
+ end
47
+ end
48
+
49
+ def add_js_alias(type, name)
50
+ instance_variable_set "@#{type.to_s}", name
51
+ end
52
+
53
+ def to_hash
54
+ {
55
+ cdn: cdn,
56
+ ir_image_tag: ir_image_tag,
57
+ ir_background: ir_background,
58
+ ir_url: ir_url,
59
+ js_class: js_class,
60
+ js_image_tag: js_image_tag,
61
+ js_background: js_background,
62
+ js_url: js_url,
63
+ modifiers: modifiers
64
+ }
65
+ end
66
+
67
+ private
68
+
69
+ def default_modifiers
70
+ {
71
+ w: { alias: :width }, h: { alias: :height },
72
+ s: { alias: :square },
73
+ c: { alias: :crop, values: %w(fit fill cut scale) },
74
+ g: { alias: :gravity, values: %w(c n s e w ne nw se sw) },
75
+ y: { alias: :top }, x: { alias: :left },
76
+ e: { alias: :external, values: default_sources },
77
+ f: { alias: :filter }
78
+ }
79
+ end
80
+
81
+ def default_sources
82
+ {
83
+ facebook: :fb_uid,
84
+ twitter: :tw_uid,
85
+ youtube: :youtube_id,
86
+ vimeo: :vimeo_id
87
+ }
88
+ end
89
+
90
+ end
91
+
92
+ end
metadata ADDED
@@ -0,0 +1,150 @@
1
+ --- !ruby/object:Gem::Specification
2
+ name: ir_helper
3
+ version: !ruby/object:Gem::Version
4
+ version: 0.2.0
5
+ platform: ruby
6
+ authors:
7
+ - James Nicol
8
+ autorequire:
9
+ bindir: bin
10
+ cert_chain: []
11
+ date: 2014-08-11 00:00:00.000000000 Z
12
+ dependencies:
13
+ - !ruby/object:Gem::Dependency
14
+ name: bundler
15
+ requirement: !ruby/object:Gem::Requirement
16
+ requirements:
17
+ - - "~>"
18
+ - !ruby/object:Gem::Version
19
+ version: '1.3'
20
+ type: :development
21
+ prerelease: false
22
+ version_requirements: !ruby/object:Gem::Requirement
23
+ requirements:
24
+ - - "~>"
25
+ - !ruby/object:Gem::Version
26
+ version: '1.3'
27
+ - !ruby/object:Gem::Dependency
28
+ name: rake
29
+ requirement: !ruby/object:Gem::Requirement
30
+ requirements:
31
+ - - ">="
32
+ - !ruby/object:Gem::Version
33
+ version: '0'
34
+ type: :development
35
+ prerelease: false
36
+ version_requirements: !ruby/object:Gem::Requirement
37
+ requirements:
38
+ - - ">="
39
+ - !ruby/object:Gem::Version
40
+ version: '0'
41
+ - !ruby/object:Gem::Dependency
42
+ name: rspec
43
+ requirement: !ruby/object:Gem::Requirement
44
+ requirements:
45
+ - - ">="
46
+ - !ruby/object:Gem::Version
47
+ version: '0'
48
+ type: :development
49
+ prerelease: false
50
+ version_requirements: !ruby/object:Gem::Requirement
51
+ requirements:
52
+ - - ">="
53
+ - !ruby/object:Gem::Version
54
+ version: '0'
55
+ - !ruby/object:Gem::Dependency
56
+ name: jasmine
57
+ requirement: !ruby/object:Gem::Requirement
58
+ requirements:
59
+ - - ">="
60
+ - !ruby/object:Gem::Version
61
+ version: '0'
62
+ type: :development
63
+ prerelease: false
64
+ version_requirements: !ruby/object:Gem::Requirement
65
+ requirements:
66
+ - - ">="
67
+ - !ruby/object:Gem::Version
68
+ version: '0'
69
+ - !ruby/object:Gem::Dependency
70
+ name: guard
71
+ requirement: !ruby/object:Gem::Requirement
72
+ requirements:
73
+ - - ">="
74
+ - !ruby/object:Gem::Version
75
+ version: '0'
76
+ type: :development
77
+ prerelease: false
78
+ version_requirements: !ruby/object:Gem::Requirement
79
+ requirements:
80
+ - - ">="
81
+ - !ruby/object:Gem::Version
82
+ version: '0'
83
+ - !ruby/object:Gem::Dependency
84
+ name: guard-rspec
85
+ requirement: !ruby/object:Gem::Requirement
86
+ requirements:
87
+ - - ">="
88
+ - !ruby/object:Gem::Version
89
+ version: '0'
90
+ type: :development
91
+ prerelease: false
92
+ version_requirements: !ruby/object:Gem::Requirement
93
+ requirements:
94
+ - - ">="
95
+ - !ruby/object:Gem::Version
96
+ version: '0'
97
+ - !ruby/object:Gem::Dependency
98
+ name: awesome_print
99
+ requirement: !ruby/object:Gem::Requirement
100
+ requirements:
101
+ - - ">="
102
+ - !ruby/object:Gem::Version
103
+ version: '0'
104
+ type: :development
105
+ prerelease: false
106
+ version_requirements: !ruby/object:Gem::Requirement
107
+ requirements:
108
+ - - ">="
109
+ - !ruby/object:Gem::Version
110
+ version: '0'
111
+ description: Helpers for use with image-resizer service
112
+ email:
113
+ - james.andrew.nicol@gmail.com
114
+ executables: []
115
+ extensions: []
116
+ extra_rdoc_files: []
117
+ files:
118
+ - LICENSE.txt
119
+ - README.md
120
+ - app/assets/javascripts/image_resizer.js.erb
121
+ - app/helpers/ir_helper/view_helper.rb
122
+ - lib/ir_helper.rb
123
+ - lib/ir_helper/engine.rb
124
+ - lib/ir_helper/helper.rb
125
+ - lib/ir_helper/version.rb
126
+ homepage: https://github.com/jimmynicol/ir-helper
127
+ licenses:
128
+ - MIT
129
+ metadata: {}
130
+ post_install_message:
131
+ rdoc_options: []
132
+ require_paths:
133
+ - lib
134
+ required_ruby_version: !ruby/object:Gem::Requirement
135
+ requirements:
136
+ - - ">="
137
+ - !ruby/object:Gem::Version
138
+ version: '0'
139
+ required_rubygems_version: !ruby/object:Gem::Requirement
140
+ requirements:
141
+ - - ">="
142
+ - !ruby/object:Gem::Version
143
+ version: '0'
144
+ requirements: []
145
+ rubyforge_project:
146
+ rubygems_version: 2.2.2
147
+ signing_key:
148
+ specification_version: 4
149
+ summary: View helpers and JS file
150
+ test_files: []