imagine 0.2.1 → 0.2.2

Sign up to get free protection for your applications and to get access to all the features.
data/README.md CHANGED
@@ -21,9 +21,11 @@ And run the migrations with:
21
21
 
22
22
  Finally, visit /imagine/albums in your browser to get started.
23
23
 
24
+ ## EXTERNAL DEPENDENCIES
25
+ Imagine uses Dragonfly, which assumes you have ImageMagick installed on your server.
26
+
24
27
  ## TODO
25
28
  * Allow a user to choose the default display style at album level
26
- * API to define a default view for albums, images (so define a default plugin)
27
29
  * Provide a standard means of wrapping with authentication
28
30
  * Provide a happy-path for attaching albums polymorphically to other objects
29
31
  * Make it look a little prettier. Provide a stylesheet that you can include if you so desire.
@@ -1,5 +1,5 @@
1
1
  module Imagine
2
- class AlbumsController < ::ApplicationController
2
+ class AlbumsController < ::Imagine::ApplicationController
3
3
  def index
4
4
  end
5
5
 
@@ -1,4 +1,4 @@
1
1
  module Imagine
2
- class ApplicationController < ActionController::Base
2
+ class ApplicationController < ::ApplicationController
3
3
  end
4
4
  end
@@ -1,5 +1,5 @@
1
1
  module Imagine
2
- class ImagesController < ::ApplicationController
2
+ class ImagesController < ::Imagine::ApplicationController
3
3
  before_filter :load_album
4
4
 
5
5
  def show
@@ -13,7 +13,7 @@ module Imagine
13
13
  def create
14
14
  load_new_image
15
15
  if ::Imagine::Warehouses::Image.save(@image)
16
- redirect_to [@album, @image], :notice => "Image has been attached!"
16
+ redirect_to @album, :notice => "Image has been attached!"
17
17
  else
18
18
  flash.now[:error] = "There was a problem creating the image."
19
19
  render :action => 'new'
@@ -1,3 +1,4 @@
1
+ %h2 Create a new album
1
2
  = form_for @album do |f|
2
3
  = f.label :name
3
4
  = f.text_field :name
@@ -2,8 +2,10 @@ module Imagine
2
2
  class Engine < ::Rails::Engine
3
3
  isolate_namespace Imagine
4
4
  end
5
- end
6
5
 
7
- # FIXME: Why can't I get this into autoload for rails?
8
- require File.expand_path('../../../app/warehouses/imagine/album', __FILE__)
9
- require File.expand_path('../../../app/warehouses/imagine/image', __FILE__)
6
+ module Warehouses
7
+ warehouses = File.expand_path('../../../app/warehouses/imagine/', __FILE__)
8
+ autoload :Album, warehouses + '/album'
9
+ autoload :Image, warehouses + '/image'
10
+ end
11
+ end
@@ -1,7 +1,7 @@
1
1
  module Imagine
2
2
  class << self
3
3
  def version
4
- %q{0.2.1}
4
+ %q{0.2.2}
5
5
  end
6
6
  end
7
7
  end
@@ -1,4 +0,0 @@
1
- # desc "Explaining what the task does"
2
- # task :imagine do
3
- # # Task goes here
4
- # end
@@ -1,15 +1,17 @@
1
1
  %h2= @album.name
2
2
  %h3 Orbit View
3
3
 
4
- .images#featured
5
- - @album.images.each do |image|
6
- = render :partial => 'imagine/images/orbit_view/image', :object => image
7
-
8
4
  = link_to "New Image", new_album_image_path(@album)
9
5
 
10
- = javascript_include_tag 'jquery.orbit-1.2.3.min.js'
11
- = stylesheet_link_tag 'orbit-1.2.3.css'
12
- :javascript
13
- $(window).load(function() {
14
- $('#featured').orbit();
15
- });
6
+ - if @album.images.any?
7
+ .images#featured
8
+ - @album.images.each do |image|
9
+ = render :partial => 'imagine/images/orbit_view/image', :object => image
10
+
11
+ = javascript_include_tag 'jquery.orbit-1.2.3.min.js'
12
+ = stylesheet_link_tag 'orbit-1.2.3.css'
13
+
14
+ :javascript
15
+ $(window).load(function() {
16
+ $('#featured').orbit();
17
+ });
@@ -2,7 +2,7 @@
2
2
 
3
3
  Gem::Specification.new do |s|
4
4
  s.name = %q{imagine-orbit_view}
5
- s.version = %q{0.1.8}
5
+ s.version = %q{0.1.9}
6
6
  s.summary = %q{Orbit slider view for Imagine}
7
7
  s.description = %q{A jquery slider album view for Imagine. Uses orbit.}
8
8
  s.date = %q{2011-09-29}
@@ -9,7 +9,7 @@ module Imagine
9
9
  plugin.pathname = root
10
10
  plugin.name = 'imagine_orbit_view'
11
11
  plugin.directory = 'orbit_view'
12
- plugin.version = %q{0.1.8}
12
+ plugin.version = %q{0.1.9}
13
13
  end
14
14
  end
15
15
 
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: imagine
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.1
4
+ version: 0.2.2
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors:
@@ -13,7 +13,7 @@ date: 2011-09-29 00:00:00.000000000Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: imagine-basic_list_view
16
- requirement: &12684640 !ruby/object:Gem::Requirement
16
+ requirement: &11332120 !ruby/object:Gem::Requirement
17
17
  none: false
18
18
  requirements:
19
19
  - - ~>
@@ -21,10 +21,10 @@ dependencies:
21
21
  version: 0.1.0
22
22
  type: :runtime
23
23
  prerelease: false
24
- version_requirements: *12684640
24
+ version_requirements: *11332120
25
25
  - !ruby/object:Gem::Dependency
26
26
  name: imagine-orbit_view
27
- requirement: &12684140 !ruby/object:Gem::Requirement
27
+ requirement: &11331620 !ruby/object:Gem::Requirement
28
28
  none: false
29
29
  requirements:
30
30
  - - ~>
@@ -32,10 +32,10 @@ dependencies:
32
32
  version: 0.1.0
33
33
  type: :runtime
34
34
  prerelease: false
35
- version_requirements: *12684140
35
+ version_requirements: *11331620
36
36
  - !ruby/object:Gem::Dependency
37
37
  name: haml-rails
38
- requirement: &12683660 !ruby/object:Gem::Requirement
38
+ requirement: &11331160 !ruby/object:Gem::Requirement
39
39
  none: false
40
40
  requirements:
41
41
  - - ! '>='
@@ -43,10 +43,10 @@ dependencies:
43
43
  version: '0'
44
44
  type: :runtime
45
45
  prerelease: false
46
- version_requirements: *12683660
46
+ version_requirements: *11331160
47
47
  - !ruby/object:Gem::Dependency
48
48
  name: dragonfly
49
- requirement: &12683080 !ruby/object:Gem::Requirement
49
+ requirement: &11330560 !ruby/object:Gem::Requirement
50
50
  none: false
51
51
  requirements:
52
52
  - - ~>
@@ -54,10 +54,10 @@ dependencies:
54
54
  version: 0.9.0
55
55
  type: :runtime
56
56
  prerelease: false
57
- version_requirements: *12683080
57
+ version_requirements: *11330560
58
58
  - !ruby/object:Gem::Dependency
59
59
  name: rack-cache
60
- requirement: &12682560 !ruby/object:Gem::Requirement
60
+ requirement: &11330040 !ruby/object:Gem::Requirement
61
61
  none: false
62
62
  requirements:
63
63
  - - ! '>='
@@ -65,10 +65,10 @@ dependencies:
65
65
  version: 0.5.3
66
66
  type: :runtime
67
67
  prerelease: false
68
- version_requirements: *12682560
68
+ version_requirements: *11330040
69
69
  - !ruby/object:Gem::Dependency
70
70
  name: rspec-rails
71
- requirement: &12682080 !ruby/object:Gem::Requirement
71
+ requirement: &11329560 !ruby/object:Gem::Requirement
72
72
  none: false
73
73
  requirements:
74
74
  - - ~>
@@ -76,10 +76,10 @@ dependencies:
76
76
  version: '2.5'
77
77
  type: :development
78
78
  prerelease: false
79
- version_requirements: *12682080
79
+ version_requirements: *11329560
80
80
  - !ruby/object:Gem::Dependency
81
81
  name: capybara
82
- requirement: &12681700 !ruby/object:Gem::Requirement
82
+ requirement: &11329180 !ruby/object:Gem::Requirement
83
83
  none: false
84
84
  requirements:
85
85
  - - ! '>='
@@ -87,10 +87,10 @@ dependencies:
87
87
  version: '0'
88
88
  type: :development
89
89
  prerelease: false
90
- version_requirements: *12681700
90
+ version_requirements: *11329180
91
91
  - !ruby/object:Gem::Dependency
92
92
  name: factory_girl
93
- requirement: &12681220 !ruby/object:Gem::Requirement
93
+ requirement: &11328700 !ruby/object:Gem::Requirement
94
94
  none: false
95
95
  requirements:
96
96
  - - ! '>='
@@ -98,10 +98,10 @@ dependencies:
98
98
  version: '0'
99
99
  type: :development
100
100
  prerelease: false
101
- version_requirements: *12681220
101
+ version_requirements: *11328700
102
102
  - !ruby/object:Gem::Dependency
103
103
  name: spork
104
- requirement: &12680760 !ruby/object:Gem::Requirement
104
+ requirement: &11328280 !ruby/object:Gem::Requirement
105
105
  none: false
106
106
  requirements:
107
107
  - - ! '>='
@@ -109,7 +109,7 @@ dependencies:
109
109
  version: '0'
110
110
  type: :development
111
111
  prerelease: false
112
- version_requirements: *12680760
112
+ version_requirements: *11328280
113
113
  description: Imagine can be dropped into an app to provide albums and images in your
114
114
  app. It supports extensions to specify new view styles.
115
115
  email: josh@isotope11.com
@@ -146,6 +146,7 @@ files:
146
146
  - basic_list_view/app/views/imagine/images/basic_list_view/_image.html.haml
147
147
  - basic_list_view/app/views/imagine/albums/basic_list_view/show.html.haml
148
148
  - basic_list_view/lib/imagine-basic_list_view.rb
149
+ - orbit_view/imagine-orbit_view-0.1.9.gem
149
150
  - orbit_view/app/assets/javascripts/jquery.orbit-1.2.3.min.js
150
151
  - orbit_view/app/assets/images/orbit/loading.gif
151
152
  - orbit_view/app/assets/images/orbit/pause-black.png
@@ -159,7 +160,6 @@ files:
159
160
  - orbit_view/app/views/imagine/images/orbit_view/_image.html.haml
160
161
  - orbit_view/app/views/imagine/albums/orbit_view/show.html.haml
161
162
  - orbit_view/lib/imagine-orbit_view.rb
162
- - orbit_view/imagine-orbit_view-0.1.8.gem
163
163
  - orbit_view/imagine-orbit_view.gemspec
164
164
  - MIT-LICENSE
165
165
  - Rakefile