sir_trevor_rails 0.5.0b1

Sign up to get free protection for your applications and to get access to all the features.
Files changed (47) hide show
  1. checksums.yaml +7 -0
  2. data/.gitignore +4 -0
  3. data/CHANGELOG +13 -0
  4. data/Gemfile +4 -0
  5. data/LICENSE.txt +22 -0
  6. data/README.md +126 -0
  7. data/Rakefile +7 -0
  8. data/app/views/sir_trevor/_sir_trevor_block_array.html.erb +1 -0
  9. data/app/views/sir_trevor/blocks/_heading_block.html.erb +1 -0
  10. data/app/views/sir_trevor/blocks/_image_block.html.erb +5 -0
  11. data/app/views/sir_trevor/blocks/_list_block.html.erb +3 -0
  12. data/app/views/sir_trevor/blocks/_quote_block.html.erb +13 -0
  13. data/app/views/sir_trevor/blocks/_text_block.html.erb +3 -0
  14. data/app/views/sir_trevor/blocks/_tweet_block.html.erb +9 -0
  15. data/app/views/sir_trevor/blocks/videos/_vimeo.html.erb +4 -0
  16. data/app/views/sir_trevor/blocks/videos/_youtube.html.erb +4 -0
  17. data/config/initializers/validators.rb +12 -0
  18. data/config.ru +7 -0
  19. data/lib/generators/sir_trevor_rails/block/block_generator.rb +33 -0
  20. data/lib/generators/sir_trevor_rails/block/templates/_block.html.erb +3 -0
  21. data/lib/generators/sir_trevor_rails/block/templates/_block.js +203 -0
  22. data/lib/generators/sir_trevor_rails/block/templates/_block.rb +2 -0
  23. data/lib/generators/sir_trevor_rails/views/views_generator.rb +17 -0
  24. data/lib/sir_trevor_rails/block.rb +63 -0
  25. data/lib/sir_trevor_rails/block_array.rb +21 -0
  26. data/lib/sir_trevor_rails/blocks/tweet_block.rb +35 -0
  27. data/lib/sir_trevor_rails/blocks/video_block.rb +9 -0
  28. data/lib/sir_trevor_rails/engine.rb +34 -0
  29. data/lib/sir_trevor_rails/has_sir_trevor_content.rb +27 -0
  30. data/lib/sir_trevor_rails/helpers/view_helper.rb +26 -0
  31. data/lib/sir_trevor_rails/version.rb +3 -0
  32. data/lib/sir_trevor_rails/view_resolver.rb +13 -0
  33. data/lib/sir_trevor_rails.rb +30 -0
  34. data/sir_trevor_rails.gemspec +39 -0
  35. data/spec/internal/app/models/custom_block.rb +5 -0
  36. data/spec/internal/app/models/post.rb +2 -0
  37. data/spec/internal/config/database.yml +3 -0
  38. data/spec/internal/config/routes.rb +3 -0
  39. data/spec/internal/db/schema.rb +7 -0
  40. data/spec/internal/log/.gitignore +1 -0
  41. data/spec/internal/public/favicon.ico +0 -0
  42. data/spec/spec_helper.rb +16 -0
  43. data/spec/unit/block_array_spec.rb +66 -0
  44. data/spec/unit/block_spec.rb +66 -0
  45. data/spec/unit/custom_block_spec.rb +19 -0
  46. data/spec/unit/has_sir_trevor_content_spec.rb +38 -0
  47. metadata +254 -0
@@ -0,0 +1,34 @@
1
+ module SirTrevorRails
2
+ class Engine < Rails::Engine
3
+
4
+ require 'redcarpet'
5
+
6
+ config.after_initialize do |app|
7
+ app.config.paths.add 'app/sir_trevor_blocks', eager_load: true
8
+ end
9
+
10
+ initializer "sir_trevor_rails.load_app_instance_data" do |app|
11
+ SirTrevorRails.setup do |config|
12
+ config.app_root = app.root
13
+ end
14
+ end
15
+
16
+ initializer "sir_trevor_rails.helpers" do
17
+ ActiveSupport.on_load :action_view do
18
+ ActionView::Base.send :include, SirTrevorRails::Helpers::ViewHelper
19
+ end
20
+ end
21
+
22
+ initializer "sir_trevor_rails.view_resolver" do
23
+ ActiveSupport.on_load :action_controller do
24
+ ActionController::Base.send :append_view_path, SirTrevorRails::ViewResolver.new
25
+ end
26
+ end
27
+
28
+ initializer "sir_trevor_rails.has_sir_trevor_content" do
29
+ ActiveSupport.on_load :active_record do
30
+ ActiveRecord::Base.send :include, SirTrevorRails::HasSirTrevorContent
31
+ end
32
+ end
33
+ end
34
+ end
@@ -0,0 +1,27 @@
1
+ require 'sir_trevor_rails/block_array'
2
+ require 'sir_trevor_rails/block'
3
+
4
+ module SirTrevorRails
5
+ module HasSirTrevorContent
6
+ extend ActiveSupport::Concern
7
+
8
+ module ClassMethods
9
+ def sir_trevor_content(*attributes)
10
+ attributes.each do |attribute|
11
+ #next unless name.constantize.column_names.include? attribute.to_s
12
+ define_attribute_reader(attribute)
13
+ end
14
+ end
15
+
16
+ private
17
+ def define_attribute_reader(attribute)
18
+ define_method attribute do
19
+ content = read_attribute(attribute)
20
+ return SirTrevorRails::BlockArray.new if content.blank?
21
+ instance_variable_get("@#{attribute}") ||
22
+ instance_variable_set("@#{attribute}", SirTrevorRails::BlockArray.from_json(content, self))
23
+ end
24
+ end
25
+ end
26
+ end
27
+ end
@@ -0,0 +1,26 @@
1
+ module SirTrevorRails
2
+ module Helpers
3
+ module ViewHelper
4
+ extend ActiveSupport::Concern
5
+
6
+ def sir_trevor_markdown(text)
7
+ Redcarpet::Render::HTML.new(hard_wrap: true, filter_html: true,
8
+ autolink: true, no_intraemphasis: true,
9
+ fenced_code: true)
10
+
11
+ markdown = Redcarpet::Markdown.new(CustomMarkdownFormatter)
12
+ markdown.render(text).html_safe
13
+ end
14
+ end
15
+ end
16
+ end
17
+
18
+ class CustomMarkdownFormatter < Redcarpet::Render::HTML
19
+ def block_code(code, language)
20
+ "<p>" << code << "</p>"
21
+ end
22
+
23
+ def codespan(code)
24
+ code
25
+ end
26
+ end
@@ -0,0 +1,3 @@
1
+ module SirTrevorRails
2
+ VERSION = "0.5.0b1"
3
+ end
@@ -0,0 +1,13 @@
1
+ module SirTrevorRails
2
+ class ViewResolver < ::ActionView::FileSystemResolver
3
+
4
+ def initialize
5
+ super("app/views")
6
+ end
7
+
8
+ def find_templates(name, prefix, partial, details)
9
+ super(name, prefix.gsub(/^(.)+(sir_trevor)/, '\2'), partial, details)
10
+ end
11
+
12
+ end
13
+ end
@@ -0,0 +1,30 @@
1
+ # Require things from Rails
2
+ require 'rails/engine'
3
+ require 'action_view'
4
+ require 'action_view/template/resolver'
5
+
6
+ require 'multi_json'
7
+
8
+ require 'sir_trevor_rails/version'
9
+ require 'sir_trevor_rails/engine'
10
+ require 'sir_trevor_rails/has_sir_trevor_content'
11
+ require 'sir_trevor_rails/view_resolver'
12
+
13
+ module SirTrevorRails
14
+
15
+ mattr_accessor :app_root
16
+
17
+ module Helpers
18
+ autoload :ViewHelper, 'sir_trevor_rails/helpers/view_helper'
19
+ end
20
+
21
+ module Blocks
22
+ autoload :TweetBlock, 'sir_trevor_rails/blocks/tweet_block'
23
+ autoload :VideoBlock, 'sir_trevor_rails/blocks/video_block'
24
+ end
25
+
26
+ def self.setup
27
+ yield self
28
+ end
29
+
30
+ end
@@ -0,0 +1,39 @@
1
+ # coding: utf-8
2
+ lib = File.expand_path('../lib', __FILE__)
3
+ $LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
4
+ require 'sir_trevor_rails/version'
5
+
6
+ Gem::Specification.new do |spec|
7
+ spec.name = "sir_trevor_rails"
8
+ spec.version = SirTrevorRails::VERSION
9
+ spec.email = ["andrew@madebymany.co.uk",
10
+ "chris@madebymany.co.uk",
11
+ "andy@madebymany.co.uk",
12
+ "lukasz@madebymany.co.uk"]
13
+ spec.authors = ["Andrew Sprinz",
14
+ "Chris Bell",
15
+ "Andrew Walker",
16
+ "Lukasz Sagol"]
17
+ spec.summary = %q{A ruby wrapper for sir trevor content}
18
+ spec.homepage = "http://madebymany.github.io/sir-trevor-js/"
19
+ spec.license = "MIT"
20
+ spec.homepage = "https://github.com/madebymany/sir-trevor-rails"
21
+
22
+ spec.files = `git ls-files`.split($/)
23
+ spec.executables = spec.files.grep(%r{^bin/}) { |f| File.basename(f) }
24
+ spec.test_files = spec.files.grep(%r{^(test|spec|features)/})
25
+ spec.require_paths = ["lib"]
26
+
27
+ spec.add_development_dependency "bundler", "~> 1.4"
28
+ spec.add_development_dependency "rake"
29
+ spec.add_development_dependency "minitest", "~> 5.3"
30
+ spec.add_development_dependency "wrong"
31
+ spec.add_development_dependency "pry-rails"
32
+ spec.add_development_dependency "combustion"
33
+ spec.add_development_dependency "sqlite3"
34
+
35
+ spec.add_dependency "rails"
36
+ spec.add_dependency "redcarpet", ">= 2.0.1", "< 4"
37
+ spec.add_dependency "twitter-text", "~> 1.4"
38
+
39
+ end
@@ -0,0 +1,5 @@
1
+ class CustomBlock < SirTrevorRails::Block
2
+ def upcase_title
3
+ title.upcase
4
+ end
5
+ end
@@ -0,0 +1,2 @@
1
+ class Post < ActiveRecord::Base
2
+ end
@@ -0,0 +1,3 @@
1
+ test:
2
+ adapter: sqlite3
3
+ database: db/combustion_test.sqlite
@@ -0,0 +1,3 @@
1
+ Rails.application.routes.draw do
2
+ #
3
+ end
@@ -0,0 +1,7 @@
1
+ ActiveRecord::Schema.define do
2
+ create_table(:posts, force: true) do |t|
3
+ t.string :title
4
+ t.text :body
5
+ t.timestamps null: false
6
+ end
7
+ end
@@ -0,0 +1 @@
1
+ *.log
File without changes
@@ -0,0 +1,16 @@
1
+ require 'sir_trevor_rails'
2
+ require 'combustion'
3
+ require 'minitest/autorun'
4
+ require 'minitest/spec'
5
+ require 'minitest/pride'
6
+ require 'wrong/adapters/minitest'
7
+ require 'pry'
8
+
9
+ Combustion.initialize! :active_record, :action_view
10
+
11
+ Wrong.config.alias_assert :expect, override: true
12
+
13
+ MiniTest::Spec.class_eval do
14
+ include Wrong::Assert
15
+ include Wrong::Helpers
16
+ end
@@ -0,0 +1,66 @@
1
+ require 'spec_helper'
2
+
3
+ module SirTrevorRails
4
+ describe BlockArray do
5
+ describe 'intialization' do
6
+ subject { BlockArray }
7
+ let(:text_block) { {type: 'text', data: {text: 'Lorem ipsum'}} }
8
+ let(:heading_block) { {type: 'heading', data: {text: 'Heading 1'}} }
9
+
10
+ it 'can be initialized with an empty JSON array' do
11
+ array = subject.from_json('[]')
12
+ expect { array.is_a? BlockArray }
13
+ end
14
+
15
+ it 'can be initialized with multiple block hashes' do
16
+ json = [text_block, heading_block].to_json
17
+ array = subject.from_json(json)
18
+
19
+ expect { array.is_a? BlockArray }
20
+ expect { array.size == 2 }
21
+ end
22
+ end
23
+
24
+ describe 'instance methods' do
25
+ let(:text_block) { {type: 'text', data: {text: 'First text block'}} }
26
+ let(:other_text_block) { {type: 'text', data: {text: 'Other text block'}} }
27
+ let(:image_block) { {type: 'image', data: {file: {url: 'http://example.com'}}} }
28
+ let(:heading_block) { {type: 'heading', data: {text: 'Heading 1'}} }
29
+ let(:json) { [image_block, text_block, heading_block, other_text_block].to_json }
30
+
31
+ subject { BlockArray.from_json(json) }
32
+
33
+ describe 'has_block_of_type?' do
34
+ it 'can be called with nonexistent block type' do
35
+ subject.has_block_of_type? :nonexistent
36
+ end
37
+
38
+ it 'returns true if block exists in the array' do
39
+ assert { subject.has_block_of_type?(:text) }
40
+ end
41
+
42
+ it 'returns false if block doesn\'t exist in the array' do
43
+ deny { subject.has_block_of_type?(:tweet) }
44
+ end
45
+ end
46
+
47
+ describe 'first_block_of_type' do
48
+ it 'returns first block of given type in the array' do
49
+ block = subject.first_block_of_type(:text)
50
+ assert { block.text == 'First text block' }
51
+ end
52
+
53
+ it 'returns nil if called with block type not in the array' do
54
+ assert { subject.first_block_of_type(:nonexistent).nil? }
55
+ end
56
+ end
57
+
58
+ describe 'to_a' do
59
+ it 'returns array with same number of elements' do
60
+ assert { subject.to_a.class == Array }
61
+ assert { subject.to_a.size == subject.size }
62
+ end
63
+ end
64
+ end
65
+ end
66
+ end
@@ -0,0 +1,66 @@
1
+ require 'spec_helper'
2
+
3
+ module SirTrevorRails
4
+ describe Block do
5
+ describe '.block_class' do
6
+ subject { Block }
7
+
8
+ describe 'for known type' do
9
+ let(:klass) { subject.block_class('tweet') }
10
+
11
+ it 'returns class' do
12
+ expect { klass == Blocks::TweetBlock }
13
+ end
14
+
15
+ it 'returned class is the one defined in file' do
16
+ expect { klass.method_defined? :at_name }
17
+ end
18
+ end
19
+
20
+ describe 'for unknown type' do
21
+ let(:klass) { subject.block_class('unknown') }
22
+
23
+ it 'defines and returns class' do
24
+ expect { klass == Blocks::UnknownBlock }
25
+ end
26
+
27
+ it 'defines class that inherits from Block' do
28
+ expect { klass.superclass == Block }
29
+ end
30
+ end
31
+ end
32
+
33
+ describe '.from_hash' do
34
+ let(:source_hash) { { type: 'test', data: {} } }
35
+ let(:block) { Block.from_hash(source_hash, nil) }
36
+
37
+ it 'initializes new block based on type field' do
38
+ expect { block.is_a? Blocks::TestBlock }
39
+ end
40
+
41
+ it 'creates accessors for all fields defined in data field' do
42
+ source_hash[:data].merge!(width: '100')
43
+
44
+ expect { block.width == '100' }
45
+ end
46
+ end
47
+
48
+ describe 'JSON representation' do
49
+ let(:source_hash) { { type: 'test', data: {} } }
50
+ let(:block) { Block.from_hash(source_hash, nil) }
51
+
52
+ it 'returns source hash when #as_json is called' do
53
+ expect { block.as_json == source_hash }
54
+ end
55
+ end
56
+
57
+ describe 'partial view lookup' do
58
+ let(:source_hash) { { type: 'test', data: {} } }
59
+ let(:block) { Block.from_hash(source_hash, nil) }
60
+
61
+ it 'uses block type to find view paritals' do
62
+ expect { block.to_partial_path == 'sir_trevor/blocks/test_block' }
63
+ end
64
+ end
65
+ end
66
+ end
@@ -0,0 +1,19 @@
1
+ require 'spec_helper'
2
+
3
+ # The block that is being tested here is defined in
4
+ # `spec/internal/app/models/custom_block.rb`, just like it would in real
5
+ # Rails app.
6
+
7
+ describe CustomBlock do
8
+ describe "SirTrevorRails::Block" do
9
+ let(:custom_block_hash) { {type: 'custom', data: {text: 'Body', title: 'name'}} }
10
+
11
+ it 'initialises class defined in the file' do
12
+ block = SirTrevorRails::Block.from_hash(custom_block_hash, nil)
13
+
14
+ assert { block.is_a? CustomBlock }
15
+ assert { block.respond_to? :upcase_title }
16
+ assert { block.upcase_title == "NAME" }
17
+ end
18
+ end
19
+ end
@@ -0,0 +1,38 @@
1
+ require 'spec_helper'
2
+
3
+ module SirTrevorRails
4
+ describe 'HasSirTrevorContent' do
5
+ describe 'initialized for body field' do
6
+ before do
7
+ Post.send(:include, HasSirTrevorContent)
8
+ Post.send(:sir_trevor_content, :body)
9
+ end
10
+
11
+ let(:post) { Post.new }
12
+ let(:text_block) { {type: 'text', data: {text: 'Lorem ipsum'}} }
13
+
14
+ it 'returns BlockArray for initialised field' do
15
+ assert { post.body.is_a? BlockArray }
16
+ end
17
+
18
+ it 'returns empty BlockArray if field is null' do
19
+ post.body = nil
20
+
21
+ assert { post.body.empty? }
22
+ end
23
+
24
+ it 'returns empty BlockArray if field is empty JSON array' do
25
+ post.body = [].to_json
26
+
27
+ assert { post.body.empty? }
28
+ end
29
+
30
+ it 'returns blocks if field is SirTrevor JSON' do
31
+ post.body = [text_block].to_json
32
+
33
+ assert { post.body.size == 1 }
34
+ assert { post.body.first.is_a? Block }
35
+ end
36
+ end
37
+ end
38
+ end
metadata ADDED
@@ -0,0 +1,254 @@
1
+ --- !ruby/object:Gem::Specification
2
+ name: sir_trevor_rails
3
+ version: !ruby/object:Gem::Version
4
+ version: 0.5.0b1
5
+ platform: ruby
6
+ authors:
7
+ - Andrew Sprinz
8
+ - Chris Bell
9
+ - Andrew Walker
10
+ - Lukasz Sagol
11
+ autorequire:
12
+ bindir: bin
13
+ cert_chain: []
14
+ date: 2015-02-25 00:00:00.000000000 Z
15
+ dependencies:
16
+ - !ruby/object:Gem::Dependency
17
+ name: bundler
18
+ requirement: !ruby/object:Gem::Requirement
19
+ requirements:
20
+ - - "~>"
21
+ - !ruby/object:Gem::Version
22
+ version: '1.4'
23
+ type: :development
24
+ prerelease: false
25
+ version_requirements: !ruby/object:Gem::Requirement
26
+ requirements:
27
+ - - "~>"
28
+ - !ruby/object:Gem::Version
29
+ version: '1.4'
30
+ - !ruby/object:Gem::Dependency
31
+ name: rake
32
+ requirement: !ruby/object:Gem::Requirement
33
+ requirements:
34
+ - - ">="
35
+ - !ruby/object:Gem::Version
36
+ version: '0'
37
+ type: :development
38
+ prerelease: false
39
+ version_requirements: !ruby/object:Gem::Requirement
40
+ requirements:
41
+ - - ">="
42
+ - !ruby/object:Gem::Version
43
+ version: '0'
44
+ - !ruby/object:Gem::Dependency
45
+ name: minitest
46
+ requirement: !ruby/object:Gem::Requirement
47
+ requirements:
48
+ - - "~>"
49
+ - !ruby/object:Gem::Version
50
+ version: '5.3'
51
+ type: :development
52
+ prerelease: false
53
+ version_requirements: !ruby/object:Gem::Requirement
54
+ requirements:
55
+ - - "~>"
56
+ - !ruby/object:Gem::Version
57
+ version: '5.3'
58
+ - !ruby/object:Gem::Dependency
59
+ name: wrong
60
+ requirement: !ruby/object:Gem::Requirement
61
+ requirements:
62
+ - - ">="
63
+ - !ruby/object:Gem::Version
64
+ version: '0'
65
+ type: :development
66
+ prerelease: false
67
+ version_requirements: !ruby/object:Gem::Requirement
68
+ requirements:
69
+ - - ">="
70
+ - !ruby/object:Gem::Version
71
+ version: '0'
72
+ - !ruby/object:Gem::Dependency
73
+ name: pry-rails
74
+ requirement: !ruby/object:Gem::Requirement
75
+ requirements:
76
+ - - ">="
77
+ - !ruby/object:Gem::Version
78
+ version: '0'
79
+ type: :development
80
+ prerelease: false
81
+ version_requirements: !ruby/object:Gem::Requirement
82
+ requirements:
83
+ - - ">="
84
+ - !ruby/object:Gem::Version
85
+ version: '0'
86
+ - !ruby/object:Gem::Dependency
87
+ name: combustion
88
+ requirement: !ruby/object:Gem::Requirement
89
+ requirements:
90
+ - - ">="
91
+ - !ruby/object:Gem::Version
92
+ version: '0'
93
+ type: :development
94
+ prerelease: false
95
+ version_requirements: !ruby/object:Gem::Requirement
96
+ requirements:
97
+ - - ">="
98
+ - !ruby/object:Gem::Version
99
+ version: '0'
100
+ - !ruby/object:Gem::Dependency
101
+ name: sqlite3
102
+ requirement: !ruby/object:Gem::Requirement
103
+ requirements:
104
+ - - ">="
105
+ - !ruby/object:Gem::Version
106
+ version: '0'
107
+ type: :development
108
+ prerelease: false
109
+ version_requirements: !ruby/object:Gem::Requirement
110
+ requirements:
111
+ - - ">="
112
+ - !ruby/object:Gem::Version
113
+ version: '0'
114
+ - !ruby/object:Gem::Dependency
115
+ name: rails
116
+ requirement: !ruby/object:Gem::Requirement
117
+ requirements:
118
+ - - ">="
119
+ - !ruby/object:Gem::Version
120
+ version: '0'
121
+ type: :runtime
122
+ prerelease: false
123
+ version_requirements: !ruby/object:Gem::Requirement
124
+ requirements:
125
+ - - ">="
126
+ - !ruby/object:Gem::Version
127
+ version: '0'
128
+ - !ruby/object:Gem::Dependency
129
+ name: redcarpet
130
+ requirement: !ruby/object:Gem::Requirement
131
+ requirements:
132
+ - - ">="
133
+ - !ruby/object:Gem::Version
134
+ version: 2.0.1
135
+ - - "<"
136
+ - !ruby/object:Gem::Version
137
+ version: '4'
138
+ type: :runtime
139
+ prerelease: false
140
+ version_requirements: !ruby/object:Gem::Requirement
141
+ requirements:
142
+ - - ">="
143
+ - !ruby/object:Gem::Version
144
+ version: 2.0.1
145
+ - - "<"
146
+ - !ruby/object:Gem::Version
147
+ version: '4'
148
+ - !ruby/object:Gem::Dependency
149
+ name: twitter-text
150
+ requirement: !ruby/object:Gem::Requirement
151
+ requirements:
152
+ - - "~>"
153
+ - !ruby/object:Gem::Version
154
+ version: '1.4'
155
+ type: :runtime
156
+ prerelease: false
157
+ version_requirements: !ruby/object:Gem::Requirement
158
+ requirements:
159
+ - - "~>"
160
+ - !ruby/object:Gem::Version
161
+ version: '1.4'
162
+ description:
163
+ email:
164
+ - andrew@madebymany.co.uk
165
+ - chris@madebymany.co.uk
166
+ - andy@madebymany.co.uk
167
+ - lukasz@madebymany.co.uk
168
+ executables: []
169
+ extensions: []
170
+ extra_rdoc_files: []
171
+ files:
172
+ - ".gitignore"
173
+ - CHANGELOG
174
+ - Gemfile
175
+ - LICENSE.txt
176
+ - README.md
177
+ - Rakefile
178
+ - app/views/sir_trevor/_sir_trevor_block_array.html.erb
179
+ - app/views/sir_trevor/blocks/_heading_block.html.erb
180
+ - app/views/sir_trevor/blocks/_image_block.html.erb
181
+ - app/views/sir_trevor/blocks/_list_block.html.erb
182
+ - app/views/sir_trevor/blocks/_quote_block.html.erb
183
+ - app/views/sir_trevor/blocks/_text_block.html.erb
184
+ - app/views/sir_trevor/blocks/_tweet_block.html.erb
185
+ - app/views/sir_trevor/blocks/videos/_vimeo.html.erb
186
+ - app/views/sir_trevor/blocks/videos/_youtube.html.erb
187
+ - config.ru
188
+ - config/initializers/validators.rb
189
+ - lib/generators/sir_trevor_rails/block/block_generator.rb
190
+ - lib/generators/sir_trevor_rails/block/templates/_block.html.erb
191
+ - lib/generators/sir_trevor_rails/block/templates/_block.js
192
+ - lib/generators/sir_trevor_rails/block/templates/_block.rb
193
+ - lib/generators/sir_trevor_rails/views/views_generator.rb
194
+ - lib/sir_trevor_rails.rb
195
+ - lib/sir_trevor_rails/block.rb
196
+ - lib/sir_trevor_rails/block_array.rb
197
+ - lib/sir_trevor_rails/blocks/tweet_block.rb
198
+ - lib/sir_trevor_rails/blocks/video_block.rb
199
+ - lib/sir_trevor_rails/engine.rb
200
+ - lib/sir_trevor_rails/has_sir_trevor_content.rb
201
+ - lib/sir_trevor_rails/helpers/view_helper.rb
202
+ - lib/sir_trevor_rails/version.rb
203
+ - lib/sir_trevor_rails/view_resolver.rb
204
+ - sir_trevor_rails.gemspec
205
+ - spec/internal/app/models/custom_block.rb
206
+ - spec/internal/app/models/post.rb
207
+ - spec/internal/config/database.yml
208
+ - spec/internal/config/routes.rb
209
+ - spec/internal/db/schema.rb
210
+ - spec/internal/log/.gitignore
211
+ - spec/internal/public/favicon.ico
212
+ - spec/spec_helper.rb
213
+ - spec/unit/block_array_spec.rb
214
+ - spec/unit/block_spec.rb
215
+ - spec/unit/custom_block_spec.rb
216
+ - spec/unit/has_sir_trevor_content_spec.rb
217
+ homepage: https://github.com/madebymany/sir-trevor-rails
218
+ licenses:
219
+ - MIT
220
+ metadata: {}
221
+ post_install_message:
222
+ rdoc_options: []
223
+ require_paths:
224
+ - lib
225
+ required_ruby_version: !ruby/object:Gem::Requirement
226
+ requirements:
227
+ - - ">="
228
+ - !ruby/object:Gem::Version
229
+ version: '0'
230
+ required_rubygems_version: !ruby/object:Gem::Requirement
231
+ requirements:
232
+ - - ">"
233
+ - !ruby/object:Gem::Version
234
+ version: 1.3.1
235
+ requirements: []
236
+ rubyforge_project:
237
+ rubygems_version: 2.2.2
238
+ signing_key:
239
+ specification_version: 4
240
+ summary: A ruby wrapper for sir trevor content
241
+ test_files:
242
+ - spec/internal/app/models/custom_block.rb
243
+ - spec/internal/app/models/post.rb
244
+ - spec/internal/config/database.yml
245
+ - spec/internal/config/routes.rb
246
+ - spec/internal/db/schema.rb
247
+ - spec/internal/log/.gitignore
248
+ - spec/internal/public/favicon.ico
249
+ - spec/spec_helper.rb
250
+ - spec/unit/block_array_spec.rb
251
+ - spec/unit/block_spec.rb
252
+ - spec/unit/custom_block_spec.rb
253
+ - spec/unit/has_sir_trevor_content_spec.rb
254
+ has_rdoc: