bootstrap_views_generator 0.1.10 → 0.1.15
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +18 -0
- data/Gemfile.lock +4 -4
- data/README.md +4 -0
- data/bootstrap_views_generator.gemspec +12 -10
- data/lib/bootstrap_views_generator.rb +4 -1
- data/lib/bootstrap_views_generator/helpers.rb +16 -0
- data/lib/bootstrap_views_generator/version.rb +4 -1
- data/lib/generators/bootstrap/devise_generator.rb +7 -1
- data/lib/generators/bootstrap/install_generator.rb +28 -9
- data/lib/generators/bootstrap/templates/devise/erb/passwords/edit.html.erb.tt +7 -7
- data/lib/generators/bootstrap/templates/devise/haml/passwords/edit.html.haml.tt +4 -4
- data/lib/generators/bootstrap/templates/devise/slim/passwords/edit.html.slim.tt +4 -4
- data/lib/generators/bootstrap/templates/layouts/application.html.erb.tt +12 -19
- data/lib/generators/bootstrap/templates/layouts/application.html.haml.tt +12 -19
- data/lib/generators/bootstrap/templates/layouts/application.html.slim.tt +12 -19
- metadata +30 -8
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 1e8a0bd048ee64107d721f90158e12aeecdeeac0b4f35f99187a42fa7027dc19
|
4
|
+
data.tar.gz: 5a82a5c01c0f544b214ec007a6f76a5cab6816bc03ce09c58391bb3c9c868fbf
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: a07e32cbfa623f93ef8857eedd0d30fade0d2b209dada912b1faea2b07418a42d4a622778115bb9325645145beb773adb361b3038ee38384901627cdbebf67c8
|
7
|
+
data.tar.gz: 6364cc3e4fa0640f2360b600e063b2b19e8defb420deeeb4427397d54c96796d60d59e00c7d2c1f4a72d0e98f2b66fba4ea3a59224b251409600eb6ba723645e
|
data/CHANGELOG.md
ADDED
@@ -0,0 +1,18 @@
|
|
1
|
+
# Changelog
|
2
|
+
|
3
|
+
All notable changes to this project will be documented in this file.
|
4
|
+
|
5
|
+
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
|
6
|
+
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
|
7
|
+
|
8
|
+
## 2021-04-17
|
9
|
+
|
10
|
+
- Correct issue with HAML page title being misaligned
|
11
|
+
- Avoid deprecation errors when pulling the application name when using Rails > 6.0 vs earlier versions
|
12
|
+
- Added logic for pulling the `app_name` into a helper to prevent duplicate logic within all the layout templates
|
13
|
+
- Minor version bump
|
14
|
+
|
15
|
+
## 2020-01-23
|
16
|
+
|
17
|
+
- Minor cleanup on ruby files (rubocop errors)
|
18
|
+
- Cleanup gemspec and added metadata so rubygems will display links for them on the gempage
|
data/Gemfile.lock
CHANGED
@@ -1,8 +1,8 @@
|
|
1
1
|
PATH
|
2
2
|
remote: .
|
3
3
|
specs:
|
4
|
-
bootstrap_views_generator (0.1.
|
5
|
-
railties (>= 4.0)
|
4
|
+
bootstrap_views_generator (0.1.14)
|
5
|
+
railties (>= 4.0, <= 7)
|
6
6
|
|
7
7
|
GEM
|
8
8
|
remote: https://rubygems.org/
|
@@ -91,9 +91,9 @@ PLATFORMS
|
|
91
91
|
DEPENDENCIES
|
92
92
|
bootstrap (~> 4.0)
|
93
93
|
bootstrap_views_generator!
|
94
|
-
bundler (>= 1.17)
|
94
|
+
bundler (>= 1.17, <= 3)
|
95
95
|
railties (>= 5.0)
|
96
|
-
rake (>=
|
96
|
+
rake (>= 7.0, <= 20.0)
|
97
97
|
|
98
98
|
BUNDLED WITH
|
99
99
|
1.17.3
|
data/README.md
CHANGED
@@ -46,6 +46,10 @@ Options:
|
|
46
46
|
# Default: false
|
47
47
|
--devise # If you want to generate bootstrap based devise views
|
48
48
|
# Default: false
|
49
|
+
--skip_javascript # If you want to skip adding javascript_include_tag || javascript_pack_tag to the layouts
|
50
|
+
# Default: false
|
51
|
+
--skip_turbolinks # Do you want to skip associating turbolinks with the assets and views
|
52
|
+
# Default: false
|
49
53
|
```
|
50
54
|
|
51
55
|
## Options
|
@@ -1,5 +1,6 @@
|
|
1
|
+
# frozen_string_literal: true
|
1
2
|
|
2
|
-
lib = File.expand_path(
|
3
|
+
lib = File.expand_path('../lib', __FILE__)
|
3
4
|
$LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
|
4
5
|
require 'bootstrap_views_generator/version'
|
5
6
|
|
@@ -9,24 +10,25 @@ Gem::Specification.new do |spec|
|
|
9
10
|
spec.authors = ['Brandon Hicks']
|
10
11
|
spec.email = ['tarellel@gmail.com']
|
11
12
|
|
12
|
-
spec.summary =
|
13
|
-
spec.description =
|
13
|
+
spec.summary = 'Bootstrap generators for overwriting the default Rails view generators'
|
14
|
+
spec.description = 'A Rails based generator for creating Bootstrap Views/layouts for for your application'
|
14
15
|
spec.homepage = 'https://github.com/tarellel/bootstrap_views_generator'
|
15
16
|
spec.license = 'MIT'
|
16
17
|
|
17
18
|
# Going off of minimum version required for Rails_v5.2.3
|
18
|
-
spec.required_ruby_version
|
19
|
+
spec.required_ruby_version = ">= #{BootstrapViewsGenerator::MIN_RUBY_VERSION}"
|
19
20
|
if spec.respond_to?(:metadata)
|
20
21
|
spec.metadata['homepage_uri'] = spec.homepage
|
21
22
|
spec.metadata['source_code_uri'] = spec.homepage
|
23
|
+
spec.metadata['bug_tracker_uri'] = "#{spec.homepage}/issues"
|
24
|
+
spec.metadata['changelog_uri'] = "#{spec.homepage}/blob/main/CHANGELOG.md"
|
22
25
|
else
|
23
|
-
raise
|
24
|
-
"public gem pushes."
|
26
|
+
raise 'RubyGems 2.0 or newer is required to protect against public gem pushes.'
|
25
27
|
end
|
26
28
|
|
27
29
|
# Specify which files should be added to the gem when it is released.
|
28
30
|
# The `git ls-files -z` loads the files in the RubyGem that have been added into git.
|
29
|
-
spec.files
|
31
|
+
spec.files = Dir.chdir(File.expand_path('..', __FILE__)) do
|
30
32
|
`git ls-files -z`.split("\x0").reject { |f| f.match(%r{^(test|spec|features)/}) }
|
31
33
|
end
|
32
34
|
# spec.files = Dir.glob("{bin,lib}/**/*") # Used when building the gem locally (before commiting and pushing the gem publically)
|
@@ -34,7 +36,7 @@ Gem::Specification.new do |spec|
|
|
34
36
|
spec.executables = spec.files.grep(%r{^exe/}) { |f| File.basename(f) }
|
35
37
|
spec.require_paths = ['lib']
|
36
38
|
|
37
|
-
spec.add_runtime_dependency 'railties', '>= 4.0'
|
38
|
-
spec.add_development_dependency 'bundler', '>= 1.17'
|
39
|
-
spec.add_development_dependency 'rake', '>=
|
39
|
+
spec.add_runtime_dependency 'railties', '>= 4.0', '<= 7'
|
40
|
+
spec.add_development_dependency 'bundler', '>= 1.17', '<= 3'
|
41
|
+
spec.add_development_dependency 'rake', '>= 7.0', '<= 20.0'
|
40
42
|
end
|
@@ -0,0 +1,16 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
module BootstrapViewsGenerator
|
4
|
+
module Helpers
|
5
|
+
# Return a cleaned up version of the name of the application being generated
|
6
|
+
# @return [String]
|
7
|
+
def app_name
|
8
|
+
# Avoid deprecation errors when pulling the application name when using Rails > 6.0
|
9
|
+
@app_name ||= if Rails.version.to_f >= 6.0
|
10
|
+
Rails.app_class.module_parent_name.demodulize.titleize
|
11
|
+
else
|
12
|
+
Rails.application.class.parent.to_s.titleize
|
13
|
+
end
|
14
|
+
end
|
15
|
+
end
|
16
|
+
end
|
@@ -1,8 +1,13 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
1
3
|
require 'rails/generators'
|
4
|
+
require_relative '../../bootstrap_views_generator/helpers'
|
2
5
|
|
3
6
|
module Bootstrap
|
4
7
|
module Generators
|
5
8
|
class DeviseGenerator < ::Rails::Generators::Base
|
9
|
+
include BootstrapViewsGenerator::Helpers
|
10
|
+
|
6
11
|
hide!
|
7
12
|
desc 'Overwrite default devise views'
|
8
13
|
source_root ::File.expand_path('../templates/devise', __FILE__)
|
@@ -47,7 +52,8 @@ module Bootstrap
|
|
47
52
|
private
|
48
53
|
def file_template_location(file_location = '')
|
49
54
|
return '' if file_location.blank?
|
50
|
-
|
55
|
+
|
56
|
+
# Depending if simpleform is to be used, it will return a path similar to one of the following:
|
51
57
|
# => slim/unlocks/new.html.slim || simple_form/slim/unlocks/new.html.slim
|
52
58
|
"#{simple_path}#{options[:template_engine]}/#{file_location}.html.#{options[:template_engine]}"
|
53
59
|
end
|
@@ -1,20 +1,39 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
1
3
|
require 'rails/generators'
|
2
4
|
require_relative 'devise_generator'
|
5
|
+
require_relative '../../bootstrap_views_generator/helpers'
|
3
6
|
|
4
7
|
module Bootstrap
|
5
8
|
module Generators
|
6
9
|
class InstallGenerator < ::Rails::Generators::Base
|
10
|
+
include BootstrapViewsGenerator::Helpers
|
7
11
|
desc 'Overwrite default view scaffolding'
|
8
12
|
source_root ::File.expand_path('../templates', __FILE__)
|
13
|
+
class_option :template_engine, type: :string, default: 'erb', aliases: '-t', enum: %w[erb slim haml],
|
14
|
+
desc: 'The template_engine to use for generating the applications views (Erb, Slim, HAML)'
|
9
15
|
|
10
|
-
class_option :template_engine, type: :string, default: 'erb', aliases: '-t', desc: 'Set template engine to generate the views with'
|
11
16
|
# Boolean flags that can be flagged by adding to the generator call ie: --pagination or --metag_tags
|
12
|
-
class_option :devise,
|
13
|
-
|
14
|
-
|
15
|
-
class_option :
|
16
|
-
|
17
|
+
class_option :devise, type: :boolean, default: false,
|
18
|
+
desc: 'If views for devise will be required by the generator'
|
19
|
+
|
20
|
+
class_option :layout, type: :boolean, default: false, aliases: '-l',
|
21
|
+
desc: 'Over-write your application layout file with a bootstrap based layout'
|
22
|
+
|
23
|
+
class_option :metatags, type: :boolean, default: false, aliases: '-m',
|
24
|
+
desc: 'If views will assign pages title using metatags gem'
|
25
|
+
|
26
|
+
class_option :pagination, type: :boolean, default: false, aliases: '-p',
|
27
|
+
desc: 'Toggle if pagination will be used with the index view/controller (based off of Pagy)'
|
28
|
+
|
29
|
+
class_option :simpleform, type: :boolean, default: false, aliases: '-sf',
|
30
|
+
desc: 'Enable SimpleForms for the form generating'
|
31
|
+
|
32
|
+
class_option :skip_javascript, type: :boolean, default: false,
|
33
|
+
desc: 'Skip adding javascript_include_tag or javascript_pack_tag to the layouts'
|
17
34
|
|
35
|
+
class_option :skip_turbolinks, type: :boolean, default: false,
|
36
|
+
desc: 'Skip associating assets and views with turbolinks'
|
18
37
|
|
19
38
|
def copy_scaffold_views
|
20
39
|
%w[edit index show new].each do |file|
|
@@ -35,8 +54,8 @@ module Bootstrap
|
|
35
54
|
copy_file("simple_form/_form.html.#{options[:template_engine]}", "lib/templates/#{options[:template_engine]}/scaffold/_form.html.#{options[:template_engine]}", force: true) if options[:simpleform]
|
36
55
|
end
|
37
56
|
|
38
|
-
# Inject Bootstrap helpers into
|
39
|
-
def
|
57
|
+
# Inject Bootstrap helpers into the application_helper file
|
58
|
+
def inject_application_helpers
|
40
59
|
pagy_helper = (options[:pagination] ? 'include Pagy::Frontend' : '')
|
41
60
|
helper_str = <<~HELPER
|
42
61
|
#{pagy_helper}
|
@@ -76,7 +95,7 @@ module Bootstrap
|
|
76
95
|
end
|
77
96
|
end
|
78
97
|
HELPER
|
79
|
-
inject_into_file 'app/helpers/application_helper.rb', optimize_indentation(helper_str,2), after: "module ApplicationHelper\n"
|
98
|
+
inject_into_file 'app/helpers/application_helper.rb', optimize_indentation(helper_str, 2), after: "module ApplicationHelper\n"
|
80
99
|
end
|
81
100
|
|
82
101
|
def invoke_devise_generator
|
@@ -9,21 +9,21 @@
|
|
9
9
|
<%%= render "devise/shared/error_messages", resource: resource %>
|
10
10
|
<%%= f.hidden_field :reset_password_token %>
|
11
11
|
|
12
|
-
<div class="
|
13
|
-
<%%= f.label :password,
|
12
|
+
<div class="form-group">
|
13
|
+
<%%= f.label :password, 'New password' %><br />
|
14
14
|
<%% if @minimum_password_length %>
|
15
15
|
<em>(<%%= @minimum_password_length %> characters minimum)</em><br />
|
16
16
|
<%% end %>
|
17
|
-
<%%= f.password_field :password, autofocus: true, autocomplete:
|
17
|
+
<%%= f.password_field :password, autofocus: true, autocomplete: 'new-password', class: 'form-control' %>
|
18
18
|
</div>
|
19
19
|
|
20
|
-
<div class="
|
21
|
-
<%%= f.label :password_confirmation,
|
22
|
-
<%%= f.password_field :password_confirmation, autocomplete:
|
20
|
+
<div class="form-group">
|
21
|
+
<%%= f.label :password_confirmation, 'Confirm new password' %><br />
|
22
|
+
<%%= f.password_field :password_confirmation, autocomplete: 'off', class: 'form-control' %>
|
23
23
|
</div>
|
24
24
|
|
25
25
|
<div class="form-group">
|
26
|
-
<%%= f.submit
|
26
|
+
<%%= f.submit 'Change my password', class: 'btn btn-primary btn-block btn-lg' %>
|
27
27
|
</div>
|
28
28
|
<%% end %>
|
29
29
|
<div class="text-center">
|
@@ -8,18 +8,18 @@
|
|
8
8
|
= form_for(resource, as: resource_name, url: password_path(resource_name), html: { method: :put }) do |f|
|
9
9
|
= render 'devise/shared/error_messages', resource: resource
|
10
10
|
= f.hidden_field :reset_password_token
|
11
|
-
.
|
11
|
+
.form-groupform-group
|
12
12
|
= f.label :password, 'New password'
|
13
13
|
%br
|
14
14
|
- if @minimum_password_length
|
15
15
|
%em
|
16
16
|
(#{@minimum_password_length} characters minimum)
|
17
17
|
%br
|
18
|
-
= f.password_field :password, autofocus: true, autocomplete: 'new-password'
|
19
|
-
.
|
18
|
+
= f.password_field :password, autofocus: true, autocomplete: 'new-password', class: 'form-control'
|
19
|
+
.form-group
|
20
20
|
= f.label :password_confirmation, 'Confirm new password'
|
21
21
|
%br
|
22
|
-
= f.password_field :password_confirmation, autocomplete: 'off'
|
22
|
+
= f.password_field :password_confirmation, autocomplete: 'off', class: 'form-control'
|
23
23
|
.form-group
|
24
24
|
= f.submit 'Change my password', class: 'btn btn-primary btn-block btn-lg'
|
25
25
|
.text-center
|
@@ -8,17 +8,17 @@
|
|
8
8
|
= form_for(resource, as: resource_name, url: password_path(resource_name), html: { method: :put }) do |f|
|
9
9
|
= render 'devise/shared/error_messages', resource: resource
|
10
10
|
= f.hidden_field :reset_password_token
|
11
|
-
.
|
11
|
+
.form-group
|
12
12
|
= f.label :password, 'New password'
|
13
13
|
br
|
14
14
|
- if @minimum_password_length
|
15
15
|
em = "(#{@minimum_password_length} characters minimum)"
|
16
16
|
br
|
17
|
-
= f.password_field :password, autofocus: true, autocomplete: 'new-password'
|
18
|
-
.
|
17
|
+
= f.password_field :password, autofocus: true, autocomplete: 'new-password', class: 'form-control'
|
18
|
+
.form-group
|
19
19
|
= f.label :password_confirmation, 'Confirm new password'
|
20
20
|
br
|
21
|
-
= f.password_field :password_confirmation, autocomplete: 'off'
|
21
|
+
= f.password_field :password_confirmation, autocomplete: 'off', class: 'form-control'
|
22
22
|
.form-group
|
23
23
|
= f.submit 'Change my password', class: 'btn btn-primary btn-block btn-lg'
|
24
24
|
.text-center
|
@@ -4,28 +4,21 @@
|
|
4
4
|
<meta charset="utf-8" />
|
5
5
|
<meta content="IE=Edge" http-equiv="X-UA-Compatible" />
|
6
6
|
<meta content="width=device-width, initial-scale=1.0" name="viewport" />
|
7
|
-
<%- if options[:metatags]
|
8
|
-
<%%= display_meta_tags site: '<%=
|
7
|
+
<%- if options[:metatags] -%>
|
8
|
+
<%%= display_meta_tags site: '<%= app_name %>' %>
|
9
9
|
<%- else -%>
|
10
|
-
<title
|
11
|
-
|
10
|
+
<title><%= app_name %></title>
|
11
|
+
<%- end -%>
|
12
12
|
<%%= csrf_meta_tags %>
|
13
13
|
<%%= csp_meta_tag %>
|
14
|
-
|
15
|
-
|
16
|
-
<%- if Gem::Version.new(Rails.version) < Gem::Version.new('6.0')
|
17
|
-
<%%= javascript_include_tag 'application' %>
|
18
|
-
<%- else
|
19
|
-
<%%= javascript_pack_tag 'application' %>
|
20
|
-
<%- end
|
21
|
-
|
22
|
-
<%%= stylesheet_link_tag 'application', media: 'all', 'data-turbolinks-track': 'reload' %>
|
23
|
-
<%- if Gem::Version.new(Rails.version) < Gem::Version.new('6.0') %>
|
24
|
-
<%%= javascript_include_tag 'application', 'data-turbolinks-track': true %>
|
25
|
-
<%- else %>
|
26
|
-
<%%= javascript_pack_tag 'application', 'data-turbolinks-track': 'reload' %>
|
27
|
-
<% end %>
|
28
|
-
<%- end -%>
|
14
|
+
<%%= stylesheet_link_tag 'application', media: 'all'<%= (options[:skip_turbolinks] || options[:skip_javascript]) ? '' : ", 'data-turbolinks-track': 'reload'" %> %>
|
15
|
+
<%- unless options[:skip_javascript] -%>
|
16
|
+
<%- if Gem::Version.new(Rails.version) < Gem::Version.new('6.0') -%>
|
17
|
+
<%%= javascript_include_tag 'application'<%= options[:skip_turbolinks] ? '' : ", 'data-turbolinks-track': true" -%> %>
|
18
|
+
<%- else -%>
|
19
|
+
<%%= javascript_pack_tag 'application'<%= options[:skip_turbolinks] ? '' : ", 'data-turbolinks-track': 'reload'" -%> %>
|
20
|
+
<%- end -%>
|
21
|
+
<%- end -%>
|
29
22
|
<!--IE Polyfill for CSS Elements-->
|
30
23
|
<!--HTML5 shim and Respond.js for IE8 support of HTML5 elements and media queries-->
|
31
24
|
<!--[if lt IE 9]>
|
@@ -5,28 +5,21 @@
|
|
5
5
|
%meta{charset: "utf-8"}/
|
6
6
|
%meta{content: "IE=Edge", "http-equiv" => "X-UA-Compatible"}/
|
7
7
|
%meta{content: "width=device-width, initial-scale=1.0", name: "viewport"}/
|
8
|
-
<%- if options[:metatags]
|
9
|
-
= display_meta_tags site: '<%=
|
10
|
-
|
11
|
-
%title
|
12
|
-
|
8
|
+
<%- if options[:metatags] -%>
|
9
|
+
= display_meta_tags site: '<%= app_name %>'
|
10
|
+
<%- else -%>
|
11
|
+
%title= '<%= app_name %>'
|
12
|
+
<%- end -%>
|
13
13
|
= csrf_meta_tags
|
14
14
|
= csp_meta_tag
|
15
|
-
|
16
|
-
|
17
|
-
<%- if Gem::Version.new(Rails.version) < Gem::Version.new('6.0')
|
18
|
-
= javascript_include_tag 'application'
|
19
|
-
<%- else
|
20
|
-
= javascript_pack_tag 'application'
|
15
|
+
= stylesheet_link_tag 'application', media: 'all'<%= (options[:skip_turbolinks] || options[:skip_javascript]) ? '' : ", 'data-turbolinks-track': 'reload'" %>
|
16
|
+
<%- unless options[:skip_javascript] -%>
|
17
|
+
<%- if Gem::Version.new(Rails.version) < Gem::Version.new('6.0') -%>
|
18
|
+
= javascript_include_tag 'application'<%= options[:skip_turbolinks] ? '' : ", 'data-turbolinks-track': true" -%>
|
19
|
+
<%- else -%>
|
20
|
+
= javascript_pack_tag 'application'<%= options[:skip_turbolinks] ? '' : ", 'data-turbolinks-track': 'reload'" -%>
|
21
|
+
<%- end -%>
|
21
22
|
<%- end %>
|
22
|
-
<%- else -%>
|
23
|
-
= stylesheet_link_tag 'application', media: 'all', 'data-turbolinks-track': 'reload'
|
24
|
-
<%- if Gem::Version.new(Rails.version) < Gem::Version.new('6.0') %>
|
25
|
-
= javascript_include_tag 'application', 'data-turbolinks-track': true
|
26
|
-
<%- else %>
|
27
|
-
= javascript_pack_tag 'application', 'data-turbolinks-track': 'reload'
|
28
|
-
<% end %>
|
29
|
-
<%- end -%>
|
30
23
|
/ IE Polyfill for CSS Elements
|
31
24
|
/ HTML5 shim and Respond.js for IE8 support of HTML5 elements and media queries
|
32
25
|
/[if lt IE 9]
|
@@ -4,28 +4,21 @@ html
|
|
4
4
|
meta charset="utf-8"
|
5
5
|
meta content="IE=Edge" http-equiv="X-UA-Compatible"
|
6
6
|
meta content="width=device-width, initial-scale=1.0" name="viewport"
|
7
|
-
<%- if options[:metatags]
|
8
|
-
= display_meta_tags site: '<%=
|
9
|
-
|
10
|
-
title
|
11
|
-
|
7
|
+
<%- if options[:metatags] -%>
|
8
|
+
= display_meta_tags site: '<%= app_name %>'
|
9
|
+
<%- else -%>
|
10
|
+
title <%= app_name %>
|
11
|
+
<%- end -%>
|
12
12
|
= csrf_meta_tags
|
13
13
|
= csp_meta_tag
|
14
|
-
|
15
|
-
|
16
|
-
<%- if Gem::Version.new(Rails.version) < Gem::Version.new('6.0')
|
17
|
-
= javascript_include_tag 'application'
|
18
|
-
<%- else
|
19
|
-
= javascript_pack_tag 'application'
|
14
|
+
= stylesheet_link_tag 'application', media: 'all'<%= (options[:skip_turbolinks] || options[:skip_javascript]) ? '' : ", 'data-turbolinks-track': 'reload'" %>
|
15
|
+
<%- unless options[:skip_javascript] -%>
|
16
|
+
<%- if Gem::Version.new(Rails.version) < Gem::Version.new('6.0') -%>
|
17
|
+
= javascript_include_tag 'application'<%= options[:skip_turbolinks] ? '' : ", 'data-turbolinks-track': true" -%>
|
18
|
+
<%- else -%>
|
19
|
+
= javascript_pack_tag 'application'<%= options[:skip_turbolinks] ? '' : ", 'data-turbolinks-track': 'reload'" -%>
|
20
|
+
<%- end -%>
|
20
21
|
<%- end %>
|
21
|
-
<%- else -%>
|
22
|
-
= stylesheet_link_tag 'application', media: 'all', 'data-turbolinks-track': 'reload'
|
23
|
-
<%- if Gem::Version.new(Rails.version) < Gem::Version.new('6.0') %>
|
24
|
-
= javascript_include_tag 'application', 'data-turbolinks-track': true
|
25
|
-
<%- else %>
|
26
|
-
= javascript_pack_tag 'application', 'data-turbolinks-track': 'reload'
|
27
|
-
<% end %>
|
28
|
-
<%- end -%>
|
29
22
|
/! IE Polyfill for CSS Elements
|
30
23
|
/! HTML5 shim and Respond.js for IE8 support of HTML5 elements and media queries
|
31
24
|
/[if lt IE 9]
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: bootstrap_views_generator
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.1.
|
4
|
+
version: 0.1.15
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Brandon Hicks
|
8
|
-
autorequire:
|
8
|
+
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2021-04-17 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: railties
|
@@ -17,6 +17,9 @@ dependencies:
|
|
17
17
|
- - ">="
|
18
18
|
- !ruby/object:Gem::Version
|
19
19
|
version: '4.0'
|
20
|
+
- - "<="
|
21
|
+
- !ruby/object:Gem::Version
|
22
|
+
version: '7'
|
20
23
|
type: :runtime
|
21
24
|
prerelease: false
|
22
25
|
version_requirements: !ruby/object:Gem::Requirement
|
@@ -24,6 +27,9 @@ dependencies:
|
|
24
27
|
- - ">="
|
25
28
|
- !ruby/object:Gem::Version
|
26
29
|
version: '4.0'
|
30
|
+
- - "<="
|
31
|
+
- !ruby/object:Gem::Version
|
32
|
+
version: '7'
|
27
33
|
- !ruby/object:Gem::Dependency
|
28
34
|
name: bundler
|
29
35
|
requirement: !ruby/object:Gem::Requirement
|
@@ -31,6 +37,9 @@ dependencies:
|
|
31
37
|
- - ">="
|
32
38
|
- !ruby/object:Gem::Version
|
33
39
|
version: '1.17'
|
40
|
+
- - "<="
|
41
|
+
- !ruby/object:Gem::Version
|
42
|
+
version: '3'
|
34
43
|
type: :development
|
35
44
|
prerelease: false
|
36
45
|
version_requirements: !ruby/object:Gem::Requirement
|
@@ -38,20 +47,29 @@ dependencies:
|
|
38
47
|
- - ">="
|
39
48
|
- !ruby/object:Gem::Version
|
40
49
|
version: '1.17'
|
50
|
+
- - "<="
|
51
|
+
- !ruby/object:Gem::Version
|
52
|
+
version: '3'
|
41
53
|
- !ruby/object:Gem::Dependency
|
42
54
|
name: rake
|
43
55
|
requirement: !ruby/object:Gem::Requirement
|
44
56
|
requirements:
|
45
57
|
- - ">="
|
46
58
|
- !ruby/object:Gem::Version
|
47
|
-
version: '
|
59
|
+
version: '7.0'
|
60
|
+
- - "<="
|
61
|
+
- !ruby/object:Gem::Version
|
62
|
+
version: '20.0'
|
48
63
|
type: :development
|
49
64
|
prerelease: false
|
50
65
|
version_requirements: !ruby/object:Gem::Requirement
|
51
66
|
requirements:
|
52
67
|
- - ">="
|
53
68
|
- !ruby/object:Gem::Version
|
54
|
-
version: '
|
69
|
+
version: '7.0'
|
70
|
+
- - "<="
|
71
|
+
- !ruby/object:Gem::Version
|
72
|
+
version: '20.0'
|
55
73
|
description: A Rails based generator for creating Bootstrap Views/layouts for for
|
56
74
|
your application
|
57
75
|
email:
|
@@ -62,6 +80,7 @@ extra_rdoc_files: []
|
|
62
80
|
files:
|
63
81
|
- ".gitignore"
|
64
82
|
- ".travis.yml"
|
83
|
+
- CHANGELOG.md
|
65
84
|
- Gemfile
|
66
85
|
- Gemfile.lock
|
67
86
|
- LICENSE.txt
|
@@ -71,6 +90,7 @@ files:
|
|
71
90
|
- bin/setup
|
72
91
|
- bootstrap_views_generator.gemspec
|
73
92
|
- lib/bootstrap_views_generator.rb
|
93
|
+
- lib/bootstrap_views_generator/helpers.rb
|
74
94
|
- lib/bootstrap_views_generator/version.rb
|
75
95
|
- lib/generators/bootstrap/config/simple_form.rb
|
76
96
|
- lib/generators/bootstrap/devise_generator.rb
|
@@ -168,7 +188,9 @@ licenses:
|
|
168
188
|
metadata:
|
169
189
|
homepage_uri: https://github.com/tarellel/bootstrap_views_generator
|
170
190
|
source_code_uri: https://github.com/tarellel/bootstrap_views_generator
|
171
|
-
|
191
|
+
bug_tracker_uri: https://github.com/tarellel/bootstrap_views_generator/issues
|
192
|
+
changelog_uri: https://github.com/tarellel/bootstrap_views_generator/blob/main/CHANGELOG.md
|
193
|
+
post_install_message:
|
172
194
|
rdoc_options: []
|
173
195
|
require_paths:
|
174
196
|
- lib
|
@@ -183,8 +205,8 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
183
205
|
- !ruby/object:Gem::Version
|
184
206
|
version: '0'
|
185
207
|
requirements: []
|
186
|
-
rubygems_version: 3.
|
187
|
-
signing_key:
|
208
|
+
rubygems_version: 3.2.11
|
209
|
+
signing_key:
|
188
210
|
specification_version: 4
|
189
211
|
summary: Bootstrap generators for overwriting the default Rails view generators
|
190
212
|
test_files: []
|