browse-everything 1.0.0.rc1 → 1.0.0.rc2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +5 -5
- data/.rubocop.yml +4 -0
- data/.travis.yml +6 -0
- data/README.md +19 -3
- data/Rakefile +0 -9
- data/app/assets/javascripts/browse_everything/behavior.js +413 -0
- data/app/assets/stylesheets/_browse_everything_bootstrap3.scss +122 -0
- data/app/assets/stylesheets/_browse_everything_bootstrap4.scss +117 -0
- data/app/assets/stylesheets/browse_everything/_browse_everything.scss +2 -116
- data/app/views/browse_everything/_providers.html.erb +2 -1
- data/app/views/browse_everything/index.html.erb +3 -2
- data/browse-everything.gemspec +0 -3
- data/karma.conf.js +71 -0
- data/lib/browse-everything.rb +0 -2
- data/lib/browse_everything.rb +10 -5
- data/lib/browse_everything/version.rb +1 -1
- data/lib/generators/browse_everything/install_generator.rb +1 -7
- data/spec/javascripts/behavior_spec.js +1 -3
- data/spec/javascripts/helpers/jquery.js +11008 -0
- data/spec/javascripts/karma_spec.rb +16 -0
- data/spec/lib/browse_everything_spec.rb +7 -0
- data/spec/test_app_templates/Gemfile.extra +7 -0
- data/spec/test_app_templates/lib/generators/test_app_generator.rb +7 -1
- metadata +11 -56
- data/app/assets/javascripts/browse_everything/behavior.js.coffee +0 -342
- data/app/assets/stylesheets/browse_everything.scss +0 -6
- data/app/helpers/font_awesome_version_helper.rb +0 -17
- data/lib/generators/browse_everything/assets_generator.rb +0 -13
- data/lib/generators/browse_everything/templates/browse_everything.scss +0 -6
- data/spec/javascripts/jasmine_spec.rb +0 -21
- data/spec/javascripts/support/jasmine.yml +0 -124
- data/spec/javascripts/support/jasmine_helper.rb +0 -16
@@ -1,17 +0,0 @@
|
|
1
|
-
# frozen_string_literal: true
|
2
|
-
|
3
|
-
module FontAwesomeVersionHelper
|
4
|
-
# Determines if the App uses Font Awesome releases 3.x or 4.x
|
5
|
-
# @return [TrueClass, FalseClass]
|
6
|
-
def font_awesome_four?
|
7
|
-
Bundler.environment.specs['font-awesome-rails'].first.version >= Gem::Version.new('4')
|
8
|
-
end
|
9
|
-
|
10
|
-
# Selects one of two HTML element classes depending upon the release of Font Awesome used by the App
|
11
|
-
# @param if3 [String] the Font Awesome 3 HTML class
|
12
|
-
# @param if4 [String] the Font Awesome 4 HTML class
|
13
|
-
# @return [String] the Font Awesome HTML class
|
14
|
-
def fa3or4(if3, if4)
|
15
|
-
font_awesome_four? ? if4 : if3
|
16
|
-
end
|
17
|
-
end
|
@@ -1,13 +0,0 @@
|
|
1
|
-
# frozen_string_literal: true
|
2
|
-
|
3
|
-
require 'rails/generators'
|
4
|
-
|
5
|
-
class BrowseEverything::AssetsGenerator < Rails::Generators::Base
|
6
|
-
desc 'This generator installs the browse_everything CSS assets into your application'
|
7
|
-
|
8
|
-
source_root File.expand_path('templates', __dir__)
|
9
|
-
|
10
|
-
def inject_css
|
11
|
-
copy_file 'browse_everything.scss', 'app/assets/stylesheets/browse_everything.scss'
|
12
|
-
end
|
13
|
-
end
|
@@ -1,21 +0,0 @@
|
|
1
|
-
# frozen_string_literal: true
|
2
|
-
|
3
|
-
require 'rake'
|
4
|
-
|
5
|
-
# Run the jasmine tests by running the jasmine:ci rake command and parses the output for failures.
|
6
|
-
# The spec will fail if any jasmine tests fails.
|
7
|
-
describe 'Jasmine' do
|
8
|
-
it 'expects all jasmine tests to pass' do
|
9
|
-
load_rake_environment ["#{jasmine_path}/lib/jasmine/tasks/jasmine.rake"]
|
10
|
-
jasmine_out = run_task 'jasmine:ci'
|
11
|
-
unless jasmine_out.include? '0 failures'
|
12
|
-
puts 'Some of the Jasmine tests failed'
|
13
|
-
puts jasmine_out
|
14
|
-
end
|
15
|
-
expect(jasmine_out).to include '0 failures'
|
16
|
-
end
|
17
|
-
end
|
18
|
-
|
19
|
-
def jasmine_path
|
20
|
-
Gem.loaded_specs['jasmine'].full_gem_path
|
21
|
-
end
|
@@ -1,124 +0,0 @@
|
|
1
|
-
# src_files
|
2
|
-
#
|
3
|
-
# Return an array of filepaths relative to src_dir to include before jasmine specs.
|
4
|
-
# Default: []
|
5
|
-
#
|
6
|
-
# EXAMPLE:
|
7
|
-
#
|
8
|
-
# src_files:
|
9
|
-
# - lib/source1.js
|
10
|
-
# - lib/source2.js
|
11
|
-
# - dist/**/*.js
|
12
|
-
#
|
13
|
-
src_files:
|
14
|
-
- assets/application.js
|
15
|
-
|
16
|
-
# stylesheets
|
17
|
-
#
|
18
|
-
# Return an array of stylesheet filepaths relative to src_dir to include before jasmine specs.
|
19
|
-
# Default: []
|
20
|
-
#
|
21
|
-
# EXAMPLE:
|
22
|
-
#
|
23
|
-
# stylesheets:
|
24
|
-
# - css/style.css
|
25
|
-
# - stylesheets/*.css
|
26
|
-
#
|
27
|
-
stylesheets:
|
28
|
-
- stylesheets/**/*.css
|
29
|
-
|
30
|
-
# helpers
|
31
|
-
#
|
32
|
-
# Return an array of filepaths relative to spec_dir to include before jasmine specs.
|
33
|
-
# Default: ["helpers/**/*.js"]
|
34
|
-
#
|
35
|
-
# EXAMPLE:
|
36
|
-
#
|
37
|
-
# helpers:
|
38
|
-
# - helpers/**/*.js
|
39
|
-
#
|
40
|
-
helpers:
|
41
|
-
- 'helpers/**/*.js'
|
42
|
-
|
43
|
-
# spec_files
|
44
|
-
#
|
45
|
-
# Return an array of filepaths relative to spec_dir to include.
|
46
|
-
# Default: ["**/*[sS]pec.js"]
|
47
|
-
#
|
48
|
-
# EXAMPLE:
|
49
|
-
#
|
50
|
-
# spec_files:
|
51
|
-
# - **/*[sS]pec.js
|
52
|
-
#
|
53
|
-
spec_files:
|
54
|
-
- '**/*[sS]pec.js*'
|
55
|
-
|
56
|
-
# src_dir
|
57
|
-
#
|
58
|
-
# Source directory path. Your src_files must be returned relative to this path. Will use root if left blank.
|
59
|
-
# Default: project root
|
60
|
-
#
|
61
|
-
# EXAMPLE:
|
62
|
-
#
|
63
|
-
# src_dir: public
|
64
|
-
#
|
65
|
-
src_dir:
|
66
|
-
|
67
|
-
# spec_dir
|
68
|
-
#
|
69
|
-
# Spec directory path. Your spec_files must be returned relative to this path.
|
70
|
-
# Default: spec/javascripts
|
71
|
-
#
|
72
|
-
# EXAMPLE:
|
73
|
-
#
|
74
|
-
# spec_dir: spec/javascripts
|
75
|
-
#
|
76
|
-
spec_dir:
|
77
|
-
|
78
|
-
# spec_helper
|
79
|
-
#
|
80
|
-
# Ruby file that Jasmine server will require before starting.
|
81
|
-
# Returned relative to your root path
|
82
|
-
# Default spec/javascripts/support/jasmine_helper.rb
|
83
|
-
#
|
84
|
-
# EXAMPLE:
|
85
|
-
#
|
86
|
-
# spec_helper: spec/javascripts/support/jasmine_helper.rb
|
87
|
-
#
|
88
|
-
spec_helper: spec/javascripts/support/jasmine_helper.rb
|
89
|
-
|
90
|
-
# boot_dir
|
91
|
-
#
|
92
|
-
# Boot directory path. Your boot_files must be returned relative to this path.
|
93
|
-
# Default: Built in boot file
|
94
|
-
#
|
95
|
-
# EXAMPLE:
|
96
|
-
#
|
97
|
-
# boot_dir: spec/javascripts/support/boot
|
98
|
-
#
|
99
|
-
boot_dir:
|
100
|
-
|
101
|
-
# boot_files
|
102
|
-
#
|
103
|
-
# Return an array of filepaths relative to boot_dir to include in order to boot Jasmine
|
104
|
-
# Default: Built in boot file
|
105
|
-
#
|
106
|
-
# EXAMPLE
|
107
|
-
#
|
108
|
-
# boot_files:
|
109
|
-
# - '**/*.js'
|
110
|
-
#
|
111
|
-
boot_files:
|
112
|
-
|
113
|
-
# rack_options
|
114
|
-
#
|
115
|
-
# Extra options to be passed to the rack server
|
116
|
-
# by default, Port and AccessLog are passed.
|
117
|
-
#
|
118
|
-
# This is an advanced options, and left empty by default
|
119
|
-
#
|
120
|
-
# EXAMPLE
|
121
|
-
#
|
122
|
-
# rack_options:
|
123
|
-
# server: 'thin'
|
124
|
-
|
@@ -1,16 +0,0 @@
|
|
1
|
-
# frozen_string_literal: true
|
2
|
-
# Use this file to set/override Jasmine configuration options
|
3
|
-
# You can remove it if you don't need it.
|
4
|
-
# This file is loaded *after* jasmine.yml is interpreted.
|
5
|
-
#
|
6
|
-
# Example: using a different boot file.
|
7
|
-
# Jasmine.configure do |config|
|
8
|
-
# config.boot_dir = '/absolute/path/to/boot_dir'
|
9
|
-
# config.boot_files = lambda { ['/absolute/path/to/boot_dir/file.js'] }
|
10
|
-
# end
|
11
|
-
#
|
12
|
-
# Example: prevent PhantomJS auto install, uses PhantomJS already on your path.
|
13
|
-
# Jasmine.configure do |config|
|
14
|
-
# config.prevent_phantom_js_auto_install = true
|
15
|
-
# end
|
16
|
-
#
|