bootswatch_rails 3.3.7.0 → 3.3.7.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: 927034123dfe5518379114e4ad2b0786636b366f
4
- data.tar.gz: 6704d9f17552dae61fbb970ab1919b0972b0a545
3
+ metadata.gz: 784e415236066a7cddfecfb402c0319f138d75a1
4
+ data.tar.gz: 84a780cdc23b18310313b5809fe9ac43cc7ffd79
5
5
  SHA512:
6
- metadata.gz: 299fcb9e3578f8424e8ea72576fc31a554dd50e812a2ec61a53e5e35fc8d5ae678c79da09622f3eef230712162ee03c1cdc1000a529fcc3c05bae942151bebfa
7
- data.tar.gz: c918b95e02209c01e4178097727b1afabca518057fb459d9838232c1b32fcb523e8350203a936b28d37e233df72d48e73385373d51bddfa12a206567406f1b97
6
+ metadata.gz: 2472e9d02c6522affecfdb254345d02e76b73731705ab723fc24d3ce098baf1235e0db8dbd870d48831a910e46aa47f991d66101acc9321c43f1d6c47908129a
7
+ data.tar.gz: fb7a6449401be4941ef8c5990db3ab5c61bd3a5463a3d8e03cf3d1216c9aaa822547246c8c1451276afb1221b9ecfd0e504fb03e1f78d127afb5191b1edc34a4
@@ -4,7 +4,7 @@ module BootswatchRails
4
4
  FONT_AWESOME = "4.6.2"
5
5
  DATATABLES = "1.10.12"
6
6
  RESPONSIVE = "2.1.0"
7
- VERSION = "3.3.7.0"
7
+ VERSION = "3.3.7.1"
8
8
 
9
9
  THEMES = [:cerulean, :cosmo, :custom, :cyborg, :darkly, :flatly, :journal, :lumen, :paper, :readable, :sandstone, :simplex, :slate, :spacelab, :superhero, :united, :yeti]
10
10
  DEFAULT = 0
@@ -12,6 +12,8 @@ module BootswatchRails
12
12
  banner: "create helper for view helpers"
13
13
  class_option :migration, type: :boolean, default: false,
14
14
  desc: 'Create a migration for added attributes'
15
+ class_option :friendly, type: :boolean, default: false,
16
+ desc: 'Add friendly_id finder for user'
15
17
  source_root File.expand_path('../templates', __FILE__)
16
18
 
17
19
  def add_helper
@@ -8,7 +8,7 @@ module CreatedByHelper
8
8
  id = model.created_by
9
9
  time = model.created_at
10
10
  end
11
- user = <%= user.camelize %>.find(id)
11
+ user = <%= user.camelize %>.<%= options.friendly? ? 'friendly.' : '' %>find(id)
12
12
  name = user.name
13
13
  email = user.email
14
14
  rescue
@@ -5,7 +5,7 @@ module BootswatchRails
5
5
  class_option :turbolinks, type: :boolean, default: false,
6
6
  desc: 'Activate turbolinks (off by default)'
7
7
  class_option :ui, type: :boolean, default: false,
8
- desc: 'Include jQuery-ui (requires jquery-ui gem)'
8
+ desc: 'Include jQuery-ui (requires jquery-ui-rails gem)'
9
9
  class_option :dt, type: :boolean, default: false,
10
10
  desc: 'Include the jQuery DataTables plugin'
11
11
  class_option :cdn, type: :string, default: 'none',
@@ -1,12 +1,12 @@
1
1
  <hr>
2
-
3
- <footer>
4
- <div class="row">
5
- <div class="col-lg-12">
2
+
3
+ <footer>
4
+ <div class="row">
5
+ <div class="col-lg-12">
6
6
  <p>
7
7
  Copyright &copy; <%= copyright_year %> <%= link_to copyright_text, copyright_link %>
8
- </p>
9
- </div>
10
- </div>
8
+ </p>
9
+ </div>
10
+ </div>
11
11
  </footer>
12
12
 
@@ -1,25 +1,25 @@
1
- <nav class="navbar navbar-default navbar-fixed-top" role="navigation">
2
- <div class="container">
3
- <div class="navbar-header">
4
- <button type="button" class="navbar-toggle" data-toggle="collapse" data-target=".navbar-collapse">
5
- <span class="sr-only"><%= t('navigation.toggle') %></span>
6
- <span class="icon-bar"></span>
7
- <span class="icon-bar"></span>
8
- <span class="icon-bar"></span>
9
- </button>
10
- <%- if brand_logo -%>
1
+ <nav class="navbar navbar-default navbar-fixed-top" role="navigation">
2
+ <div class="container">
3
+ <div class="navbar-header">
4
+ <button type="button" class="navbar-toggle" data-toggle="collapse" data-target=".navbar-collapse">
5
+ <span class="sr-only"><%= t('navigation.toggle') %></span>
6
+ <span class="icon-bar"></span>
7
+ <span class="icon-bar"></span>
8
+ <span class="icon-bar"></span>
9
+ </button>
10
+ <%- if brand_logo -%>
11
11
  <%= link_to brand_logo, copyright_link, class: "navbar-brand" %>
12
- <%- end -%>
12
+ <%- end -%>
13
13
  </div>
14
-
14
+
15
15
  <div class="navbar-collapse collapse">
16
16
  <ul class="nav navbar-nav navbar-left">
17
17
  <%= render 'layouts/navbar_left' %>
18
- </ul>
18
+ </ul>
19
19
  <ul class="nav navbar-nav navbar-right">
20
20
  <%= render 'layouts/navbar_right' %>
21
- </ul>
22
- </div>
23
- </div>
24
- </nav>
21
+ </ul>
22
+ </div>
23
+ </div>
24
+ </nav>
25
25
 
@@ -5,18 +5,18 @@
5
5
  <body>
6
6
  <%= render 'layouts/topnav' %>
7
7
 
8
- <div class="container" id="main-content">
8
+ <div class="container" id="main-content">
9
9
  <div class="row">
10
- <div class="col-md-9">
10
+ <div class="col-md-9">
11
11
  <%= render 'layouts/flash' %>
12
12
  <%= yield %>
13
- </div>
13
+ </div>
14
14
  <div class="col-md-3 well">
15
- <%= render 'layouts/sidebar' %>
16
- </div>
17
- </div>
18
- </div>
19
-
15
+ <%= render 'layouts/sidebar' %>
16
+ </div>
17
+ </div>
18
+ </div>
19
+
20
20
  <%= render 'layouts/footer' %>
21
21
  </body>
22
22
  </html>
@@ -5,15 +5,15 @@
5
5
  <body>
6
6
  <%= render 'layouts/topnav' %>
7
7
 
8
- <div class="container" id="main-content">
9
- <div class="row">
10
- <div class="col-md-6 col-md-offset-3">
8
+ <div class="container" id="main-content">
9
+ <div class="row">
10
+ <div class="col-md-6 col-md-offset-3">
11
11
  <%= render 'layouts/flash' %>
12
12
  <%= yield %>
13
- </div>
14
- </div>
15
- </div>
16
-
13
+ </div>
14
+ </div>
15
+ </div>
16
+
17
17
  <%= render 'layouts/footer' %>
18
18
  </body>
19
19
  </html>
@@ -2,12 +2,12 @@
2
2
  // listed below.
3
3
  //
4
4
  // Any JavaScript/Coffee file within this directory, lib/assets/javascripts, vendor/assets/javascripts,
5
- // or vendor/assets/javascripts of plugins, if any, can be referenced here using a relative path.
5
+ // or any plugin's vendor/assets/javascripts directory can be referenced here using a relative path.
6
6
  //
7
7
  // It's not advisable to add code directly here, but if you do, it'll appear at the bottom of the
8
- // compiled file.
8
+ // compiled file. JavaScript code in this file should be added after the last require_* statement.
9
9
  //
10
- // Read Sprockets README (https://github.com/sstephenson/sprockets#sprockets-directives) for details
10
+ // Read Sprockets README (https://github.com/rails/sprockets#sprockets-directives) for details
11
11
  // about supported directives.
12
12
  //
13
13
  <%- if options.cdn == "none" -%>
@@ -7,13 +7,18 @@ module BootswatchRails
7
7
  argument :name, type: :string,
8
8
  desc: "The resource to be updated"
9
9
  argument :actions, type: :array,
10
- banner: "the actions to be publicly available"
10
+ banner: "the actions to be publicly available or 'all'"
11
11
 
12
12
  def update_controller
13
13
  file = "app/controllers/#{table_name}_controller.rb"
14
- list = actions.map{|a| ":#{a}"}.join(', ')
14
+ if actions.include?('all')
15
+ text = ""
16
+ else
17
+ list = actions.map{|a| ":#{a}"}.join(', ')
18
+ text = ", only: [#{list}]"
19
+ end
15
20
  inject_into_file file, after: /before_action :set.*$/ do
16
- "\n skip_before_action :require_login, only: [#{list}]"
21
+ "\n skip_before_action :require_login#{text}"
17
22
  end
18
23
  end
19
24
  end
@@ -7,7 +7,7 @@ module BootswatchRails
7
7
  argument :name, type: :string, default: "user",
8
8
  banner: "name of the user model"
9
9
  class_option :picture, type: :boolean, default: false,
10
- desc: 'Add picture to user (needs carrierwave)'
10
+ desc: 'Add picture to user (needs carrierwave gem)'
11
11
  class_option :gravatar, type: :boolean, default: false,
12
12
  desc: 'Add Gravatar image to user (uses email)'
13
13
  class_option :authority, type: :boolean, default: false,
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: bootswatch_rails
3
3
  version: !ruby/object:Gem::Version
4
- version: 3.3.7.0
4
+ version: 3.3.7.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Volker Wiegand
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2016-09-02 00:00:00.000000000 Z
11
+ date: 2016-09-07 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: railties