rails_layout 1.0.0 → 1.0.1

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 50274237c3f45d7435ac0ce7f03fc6d0da91e5d7
4
- data.tar.gz: 4ca540793d7902b02e5c8b353b0eab95eb6b4c6b
3
+ metadata.gz: 344c355dc7579793e096b4731fcf3180dc013dbc
4
+ data.tar.gz: 29a7570f22a064cc3f57084258fc96028dcf4386
5
5
  SHA512:
6
- metadata.gz: 888f101447c945b748df08d79c4c36583543a3f9ab941824abf354392232fcb72ed9757c9f12a81b1257bcb7e14737ba1d2c69146c2372b36df78c17b210d0e9
7
- data.tar.gz: ee091c04a581aabc3635f289233222ff896b5ed8e272b61e5ca44f3a3696cd3f329cb2094448896b57f257c0ccc04c51cf49c7a7b9082f4afae0b5f7844504cf
6
+ metadata.gz: 007e63ab70a9d53591ba185a3aa3ebdc00ed04c871f95a67844d1f7fafa3ccea613e68292ebde550c0da2a937cf0b16ae2096087b78d780b1b56d1220e4a0ee1
7
+ data.tar.gz: 70406d4f7e327dc175696d05c62c160fdbb37e6d1b5d514e8c2fe46a146998fa3175a0954e2dffbbe9b6750763f61813b0331a20d3696a4146ede52edb122b0b
data/CHANGELOG.textile CHANGED
@@ -1,5 +1,9 @@
1
1
  h1. CHANGELOG
2
2
 
3
+ h3. 1.0.1 January 9, 2014
4
+
5
+ * generate Devise views (new account, edit account, forgot password)
6
+
3
7
  h3. 1.0.0 January 9, 2014
4
8
 
5
9
  * generate Devise views (login view)
data/README.textile CHANGED
@@ -15,6 +15,12 @@ h4. Rails Composer
15
15
 
16
16
  The RailsLayout gem is used by "Rails Composer":http://railsapps.github.io/rails-composer/ tool, an application template used to create starter applications. You can use Rails Composer to generate entire applications.
17
17
 
18
+ h4. !http://railsapps.github.io/images/join/join-railsapps.png(Join RailsApps)!:http://railsapps.github.io/
19
+
20
+ h4. Support the RailsApps Project
21
+
22
+ If the RailsLayout gem is useful to you, please accept our invitation to "join the RailsApps project":http://railsapps.github.io/. The RailsApps project provides example applications, tutorials, and starter tools, including the RailsLayout gem.
23
+
18
24
  h2. Command Summary
19
25
 
20
26
  h4. Generate Application Layout, Navigation, and Flash Message Files
@@ -389,9 +395,8 @@ h2. The "layout:devise" Command
389
395
 
390
396
  Use the RailsLayout gem to generate Devise views with styling for Bootstrap or Foundation.
391
397
 
392
- <pre>
393
- $ rails generate layout:devise
394
- </pre>
398
+ * @$ rails generate layout:devise foundation5@
399
+ * @$ rails generate layout:devise bootstrap3@
395
400
 
396
401
  The command will create (or replace) these files:
397
402
 
@@ -404,6 +409,10 @@ Additionally, the command will append Sass mixins to accommodate Bootstrap or Fo
404
409
 
405
410
  The Sass mixins allow any view to be used with either Bootstrap or Foundation (so we don't have to maintain separate views for each front-end framework).
406
411
 
412
+ h4. Limitations
413
+
414
+ At this time, with the "layout:devise" command, only Foundation 5 or Bootstrap 3 are supported. Files are not generated for Haml or Slim.
415
+
407
416
  h2. Issues
408
417
 
409
418
  Any issues? Please create an "issue":http://github.com/RailsApps/rails_layout/issues on GitHub. Reporting issues (and patching!) helps everyone.
@@ -30,6 +30,9 @@ module Layout
30
30
  # Add Devise views
31
31
  def add_devise_views
32
32
  copy_file 'sessions/new.html.erb', 'app/views/devise/sessions/new.html.erb'
33
+ copy_file 'passwords/new.html.erb', 'app/views/devise/passwords/new.html.erb'
34
+ copy_file 'registrations/new.html.erb', 'app/views/devise/registrations/new.html.erb'
35
+ copy_file 'registrations/edit.html.erb', 'app/views/devise/registrations/edit.html.erb'
33
36
  end
34
37
 
35
38
  end
@@ -10,6 +10,7 @@
10
10
  .authform form {
11
11
  @extend .well;
12
12
  @extend .well-lg;
13
+ padding-bottom: 40px;
13
14
  }
14
15
  .authform .right {
15
16
  float: right !important;
@@ -18,3 +19,13 @@
18
19
  @extend .btn;
19
20
  @extend .btn-primary;
20
21
  }
22
+ .authform fieldset {
23
+ @extend .well;
24
+ }
25
+ #error_explanation {
26
+ @extend .alert;
27
+ @extend .alert-danger;
28
+ }
29
+ #error_explanation h2 {
30
+ font-size: 16px;
31
+ }
@@ -9,11 +9,14 @@
9
9
  }
10
10
  .authform form {
11
11
  @include panel();
12
- padding-bottom: 40px;
12
+ padding-bottom: 60px;
13
13
  }
14
14
  .authform form a {
15
15
  font-size: rem-calc(13);
16
16
  }
17
+ .authform form p {
18
+ font-size: rem-calc(13);
19
+ }
17
20
  .authform .form-group {
18
21
  // for Bootstrap, not used for Foundation
19
22
  }
@@ -23,3 +26,14 @@
23
26
  .authform .checkbox {
24
27
  // for Bootstrap, not used for Foundation
25
28
  }
29
+ .authform fieldset {
30
+ @include panel();
31
+ }
32
+ .authform #error_explanation {
33
+ @extend .alert-box;
34
+ @extend .alert;
35
+ }
36
+ .authform #error_explanation h2 {
37
+ font-size: rem-calc(16);
38
+ color: white;
39
+ }
@@ -0,0 +1,12 @@
1
+ <div class="authform">
2
+ <%= form_for(resource, :as => resource_name, :url => password_path(resource_name), :html => { :method => :post, :role => 'form'}) do |f| %>
3
+ <h3>Forgot your password?</h3>
4
+ <p>We'll send password reset instructions.</p>
5
+ <%= devise_error_messages! %>
6
+ <div class="form-group">
7
+ <%= f.label :email %>
8
+ <%= f.email_field :email, :autofocus => true, class: 'form-control' %>
9
+ </div>
10
+ <%= f.submit 'Reset Password', :class => 'button right' %>
11
+ <% end %>
12
+ </div>
@@ -0,0 +1,41 @@
1
+ <div class="authform">
2
+ <h3>Edit <%= resource_name.to_s.humanize %></h3>
3
+ <%= form_for(resource, :as => resource_name, :url => registration_path(resource_name), :html => { :method => :put, :role => 'form'}) do |f| %>
4
+ <%= devise_error_messages! %>
5
+ <div class="form-group">
6
+ <%= f.label :name %>
7
+ <%= f.text_field :name, :autofocus => true, class: 'form-control' %>
8
+ </div>
9
+ <div class="form-group">
10
+ <%= f.label :email %>
11
+ <%= f.email_field :email, class: 'form-control' %>
12
+ <% if devise_mapping.confirmable? && resource.pending_reconfirmation? %>
13
+ <div>Currently waiting confirmation for: <%= resource.unconfirmed_email %></div>
14
+ <% end %>
15
+ </div>
16
+ <fieldset>
17
+ <p>Leave these fields blank if you don't want to change your password.</p>
18
+ <div class="form-group">
19
+ <%= f.label :password %>
20
+ <%= f.password_field :password, :autocomplete => 'off', class: 'form-control' %>
21
+ </div>
22
+ <div class="form-group">
23
+ <%= f.label :password_confirmation %>
24
+ <%= f.password_field :password_confirmation, class: 'form-control' %>
25
+ </div>
26
+ </fieldset>
27
+ <fieldset>
28
+ <p>You must enter your current password to make changes.</p>
29
+ <div class="form-group">
30
+ <%= f.label :current_password %>
31
+ <%= f.password_field :current_password, class: 'form-control' %>
32
+ </div>
33
+ </fieldset>
34
+ <%= f.submit 'Update', :class => 'button right' %>
35
+ <% end %>
36
+ </div>
37
+ <div class="authform">
38
+ <h3>Cancel Account</h3>
39
+ <p>Unhappy? We'll be sad to see you go.</p>
40
+ <%= button_to "Cancel my account", registration_path(resource_name), :data => { :confirm => "Are you sure?" }, :method => :delete, :class => 'button right' %>
41
+ </div>
@@ -0,0 +1,23 @@
1
+ <div class="authform">
2
+ <%= form_for(resource, :as => resource_name, :url => registration_path(resource_name), :html => { :role => 'form'}) do |f| %>
3
+ <h3>Sign up</h3>
4
+ <%= devise_error_messages! %>
5
+ <div class="form-group">
6
+ <%= f.label :name %>
7
+ <%= f.text_field :name, :autofocus => true, class: 'form-control' %>
8
+ </div>
9
+ <div class="form-group">
10
+ <%= f.label :email %>
11
+ <%= f.email_field :email, class: 'form-control' %>
12
+ </div>
13
+ <div class="form-group">
14
+ <%= f.label :password %>
15
+ <%= f.password_field :password, class: 'form-control' %>
16
+ </div>
17
+ <div class="form-group">
18
+ <%= f.label :password_confirmation %>
19
+ <%= f.password_field :password_confirmation, class: 'form-control' %>
20
+ </div>
21
+ <%= f.submit 'Sign up', :class => 'button right' %>
22
+ <% end %>
23
+ </div>
@@ -1,3 +1,3 @@
1
1
  module RailsLayout
2
- VERSION = "1.0.0"
2
+ VERSION = "1.0.1"
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: rails_layout
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.0
4
+ version: 1.0.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Daniel Kehoe
@@ -58,6 +58,9 @@ files:
58
58
  - lib/generators/layout/devise/templates/.DS_Store
59
59
  - lib/generators/layout/devise/templates/bootstrap3.css.scss
60
60
  - lib/generators/layout/devise/templates/foundation5.css.scss
61
+ - lib/generators/layout/devise/templates/passwords/new.html.erb
62
+ - lib/generators/layout/devise/templates/registrations/edit.html.erb
63
+ - lib/generators/layout/devise/templates/registrations/new.html.erb
61
64
  - lib/generators/layout/devise/templates/sessions/new.html.erb
62
65
  - lib/generators/layout/install/.DS_Store
63
66
  - lib/generators/layout/install/install_generator.rb