rails-sweetalert2-confirm 0.9.0
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 +7 -0
- data/.gitignore +11 -0
- data/.travis.yml +17 -0
- data/Gemfile +3 -0
- data/MIT-LICENSE +20 -0
- data/README.md +222 -0
- data/Rakefile +12 -0
- data/lib/assets/javascripts/rails_sweetalert2_confirm.js +163 -0
- data/lib/rails_sweetalert2_confirm.rb +7 -0
- data/lib/rails_sweetalert2_confirm/rails/engine.rb +6 -0
- data/lib/rails_sweetalert2_confirm/railtie.rb +8 -0
- data/lib/rails_sweetalert2_confirm/version.rb +3 -0
- data/lib/rails_sweetalert2_confirm/view_helpers.rb +50 -0
- data/rails_sweetalert2_confirm.gemspec +29 -0
- data/spec/dummy/.gitignore +2 -0
- data/spec/dummy/.rspec +1 -0
- data/spec/dummy/Rakefile +6 -0
- data/spec/dummy/app/assets/javascripts/application.js +16 -0
- data/spec/dummy/app/assets/javascripts/application_turbolinks.js +17 -0
- data/spec/dummy/app/assets/stylesheets/application.css +3 -0
- data/spec/dummy/app/controllers/application_controller.rb +19 -0
- data/spec/dummy/app/views/application/destroy.html.erb +1 -0
- data/spec/dummy/app/views/application/destroy.js.erb +1 -0
- data/spec/dummy/app/views/application/index.html.erb +42 -0
- data/spec/dummy/app/views/layouts/application.html.erb +19 -0
- data/spec/dummy/bin/bundle +3 -0
- data/spec/dummy/bin/rails +4 -0
- data/spec/dummy/bin/rake +4 -0
- data/spec/dummy/config.ru +4 -0
- data/spec/dummy/config/application.rb +29 -0
- data/spec/dummy/config/boot.rb +5 -0
- data/spec/dummy/config/database.yml +25 -0
- data/spec/dummy/config/environment.rb +5 -0
- data/spec/dummy/config/environments/development.rb +37 -0
- data/spec/dummy/config/environments/production.rb +78 -0
- data/spec/dummy/config/environments/test.rb +43 -0
- data/spec/dummy/config/initializers/assets.rb +8 -0
- data/spec/dummy/config/initializers/backtrace_silencers.rb +7 -0
- data/spec/dummy/config/initializers/cookies_serializer.rb +3 -0
- data/spec/dummy/config/initializers/filter_parameter_logging.rb +4 -0
- data/spec/dummy/config/initializers/inflections.rb +16 -0
- data/spec/dummy/config/initializers/mime_types.rb +4 -0
- data/spec/dummy/config/initializers/secret_token.rb +1 -0
- data/spec/dummy/config/initializers/session_store.rb +3 -0
- data/spec/dummy/config/initializers/wrap_parameters.rb +14 -0
- data/spec/dummy/config/locales/en.yml +23 -0
- data/spec/dummy/config/routes.rb +5 -0
- data/spec/dummy/config/secrets.yml +22 -0
- data/spec/dummy/log/.keep +0 -0
- data/spec/dummy/public/404.html +67 -0
- data/spec/dummy/public/422.html +67 -0
- data/spec/dummy/public/500.html +66 -0
- data/spec/dummy/public/favicon.ico +0 -0
- data/spec/features/rails_sweetalert2_confirm_spec.rb +109 -0
- data/spec/spec_helper.rb +48 -0
- data/tags +20 -0
- metadata +241 -0
data/spec/spec_helper.rb
ADDED
@@ -0,0 +1,48 @@
|
|
1
|
+
# This file is copied to spec/ when you run 'rails generate rspec:install'
|
2
|
+
ENV["RAILS_ENV"] ||= 'test'
|
3
|
+
require File.expand_path("../dummy/config/environment", __FILE__)
|
4
|
+
require 'rspec/rails'
|
5
|
+
require 'rspec/autorun'
|
6
|
+
require 'capybara/rspec'
|
7
|
+
|
8
|
+
# Requires supporting ruby files with custom matchers and macros, etc,
|
9
|
+
# in spec/support/ and its subdirectories.
|
10
|
+
Dir[Rails.root.join("spec/support/**/*.rb")].each { |f| require f }
|
11
|
+
|
12
|
+
# Checks for pending migrations before tests are run.
|
13
|
+
# If you are not using ActiveRecord, you can remove this line.
|
14
|
+
#ActiveRecord::Migration.check_pending! if defined?(ActiveRecord::Migration)
|
15
|
+
|
16
|
+
RSpec.configure do |config|
|
17
|
+
# ## Mock Framework
|
18
|
+
#
|
19
|
+
# If you prefer to use mocha, flexmock or RR, uncomment the appropriate line:
|
20
|
+
#
|
21
|
+
# config.mock_with :mocha
|
22
|
+
# config.mock_with :flexmock
|
23
|
+
# config.mock_with :rr
|
24
|
+
|
25
|
+
# Remove this line if you're not using ActiveRecord or ActiveRecord fixtures
|
26
|
+
config.fixture_path = "#{::Rails.root}/spec/fixtures"
|
27
|
+
|
28
|
+
# If you're not using ActiveRecord, or you'd prefer not to run each of your
|
29
|
+
# examples within a transaction, remove the following line or assign false
|
30
|
+
# instead of true.
|
31
|
+
config.use_transactional_fixtures = true
|
32
|
+
|
33
|
+
# If true, the base class of anonymous controllers will be inferred
|
34
|
+
# automatically. This will be the default behavior in future versions of
|
35
|
+
# rspec-rails.
|
36
|
+
config.infer_base_class_for_anonymous_controllers = false
|
37
|
+
|
38
|
+
# Run specs in random order to surface order dependencies. If you find an
|
39
|
+
# order dependency and want to debug it, you can fix the order by providing
|
40
|
+
# the seed, which is printed after each run.
|
41
|
+
# --seed 1234
|
42
|
+
config.order = "random"
|
43
|
+
|
44
|
+
#Capybara
|
45
|
+
config.include Capybara::DSL
|
46
|
+
require 'capybara/poltergeist'
|
47
|
+
Capybara.javascript_driver = :poltergeist
|
48
|
+
end
|
data/tags
ADDED
@@ -0,0 +1,20 @@
|
|
1
|
+
!_TAG_FILE_FORMAT 2 /extended format; --format=1 will not append ;" to lines/
|
2
|
+
!_TAG_FILE_SORTED 1 /0=unsorted, 1=sorted, 2=foldcase/
|
3
|
+
!_TAG_PROGRAM_AUTHOR Darren Hiebert /dhiebert@users.sourceforge.net/
|
4
|
+
!_TAG_PROGRAM_NAME Exuberant Ctags //
|
5
|
+
!_TAG_PROGRAM_URL http://ctags.sourceforge.net /official site/
|
6
|
+
!_TAG_PROGRAM_VERSION 5.8 //
|
7
|
+
Engine lib/rails_sweetalert2_confirm/rails/engine.rb /^ class Engine < ::Rails::Engine$/;" c class:RailsSweetAlert2Confirm.Rails
|
8
|
+
Rails lib/rails_sweetalert2_confirm/rails/engine.rb /^ module Rails$/;" m class:RailsSweetAlert2Confirm
|
9
|
+
RailsSweetAlert2Confirm lib/rails-sweetalert2-confirm.rb /^module RailsSweetAlert2Confirm$/;" m
|
10
|
+
RailsSweetAlert2Confirm lib/rails_sweetalert2_confirm/rails/engine.rb /^module RailsSweetAlert2Confirm$/;" m
|
11
|
+
RailsSweetAlert2Confirm lib/rails_sweetalert2_confirm/railtie.rb /^module RailsSweetAlert2Confirm$/;" m
|
12
|
+
RailsSweetAlert2Confirm lib/rails_sweetalert2_confirm/version.rb /^module RailsSweetAlert2Confirm$/;" m
|
13
|
+
RailsSweetAlert2Confirm lib/rails_sweetalert2_confirm/view_helpers.rb /^module RailsSweetAlert2Confirm$/;" m
|
14
|
+
Railtie lib/rails_sweetalert2_confirm/railtie.rb /^ class Railtie < Rails::Railtie$/;" c class:RailsSweetAlert2Confirm
|
15
|
+
ViewHelpers lib/rails_sweetalert2_confirm/view_helpers.rb /^ module ViewHelpers$/;" m class:RailsSweetAlert2Confirm
|
16
|
+
button_tag lib/rails_sweetalert2_confirm/view_helpers.rb /^ def button_tag(*args, &block)$/;" f class:RailsSweetAlert2Confirm.ViewHelpers
|
17
|
+
link_to lib/rails_sweetalert2_confirm/view_helpers.rb /^ def link_to(*args, &block)$/;" f class:RailsSweetAlert2Confirm.ViewHelpers
|
18
|
+
options_has_confirm? lib/rails_sweetalert2_confirm/view_helpers.rb /^ def options_has_confirm?(options)$/;" f class:RailsSweetAlert2Confirm.ViewHelpers
|
19
|
+
replace_confirm_with_swal lib/rails_sweetalert2_confirm/view_helpers.rb /^ def replace_confirm_with_swal(options)$/;" f class:RailsSweetAlert2Confirm.ViewHelpers
|
20
|
+
submit_tag lib/rails_sweetalert2_confirm/view_helpers.rb /^ def submit_tag(value = 'Save changes', options = {})$/;" f class:RailsSweetAlert2Confirm.ViewHelpers
|
metadata
ADDED
@@ -0,0 +1,241 @@
|
|
1
|
+
--- !ruby/object:Gem::Specification
|
2
|
+
name: rails-sweetalert2-confirm
|
3
|
+
version: !ruby/object:Gem::Version
|
4
|
+
version: 0.9.0
|
5
|
+
platform: ruby
|
6
|
+
authors:
|
7
|
+
- Joe Woodward
|
8
|
+
autorequire:
|
9
|
+
bindir: bin
|
10
|
+
cert_chain: []
|
11
|
+
date: 2016-07-21 00:00:00.000000000 Z
|
12
|
+
dependencies:
|
13
|
+
- !ruby/object:Gem::Dependency
|
14
|
+
name: rails
|
15
|
+
requirement: !ruby/object:Gem::Requirement
|
16
|
+
requirements:
|
17
|
+
- - ">="
|
18
|
+
- !ruby/object:Gem::Version
|
19
|
+
version: '4'
|
20
|
+
type: :development
|
21
|
+
prerelease: false
|
22
|
+
version_requirements: !ruby/object:Gem::Requirement
|
23
|
+
requirements:
|
24
|
+
- - ">="
|
25
|
+
- !ruby/object:Gem::Version
|
26
|
+
version: '4'
|
27
|
+
- !ruby/object:Gem::Dependency
|
28
|
+
name: rspec-rails
|
29
|
+
requirement: !ruby/object:Gem::Requirement
|
30
|
+
requirements:
|
31
|
+
- - "~>"
|
32
|
+
- !ruby/object:Gem::Version
|
33
|
+
version: '3.5'
|
34
|
+
type: :development
|
35
|
+
prerelease: false
|
36
|
+
version_requirements: !ruby/object:Gem::Requirement
|
37
|
+
requirements:
|
38
|
+
- - "~>"
|
39
|
+
- !ruby/object:Gem::Version
|
40
|
+
version: '3.5'
|
41
|
+
- !ruby/object:Gem::Dependency
|
42
|
+
name: capybara
|
43
|
+
requirement: !ruby/object:Gem::Requirement
|
44
|
+
requirements:
|
45
|
+
- - "~>"
|
46
|
+
- !ruby/object:Gem::Version
|
47
|
+
version: '2.1'
|
48
|
+
type: :development
|
49
|
+
prerelease: false
|
50
|
+
version_requirements: !ruby/object:Gem::Requirement
|
51
|
+
requirements:
|
52
|
+
- - "~>"
|
53
|
+
- !ruby/object:Gem::Version
|
54
|
+
version: '2.1'
|
55
|
+
- !ruby/object:Gem::Dependency
|
56
|
+
name: pry
|
57
|
+
requirement: !ruby/object:Gem::Requirement
|
58
|
+
requirements:
|
59
|
+
- - "~>"
|
60
|
+
- !ruby/object:Gem::Version
|
61
|
+
version: '0.10'
|
62
|
+
type: :development
|
63
|
+
prerelease: false
|
64
|
+
version_requirements: !ruby/object:Gem::Requirement
|
65
|
+
requirements:
|
66
|
+
- - "~>"
|
67
|
+
- !ruby/object:Gem::Version
|
68
|
+
version: '0.10'
|
69
|
+
- !ruby/object:Gem::Dependency
|
70
|
+
name: jquery-rails
|
71
|
+
requirement: !ruby/object:Gem::Requirement
|
72
|
+
requirements:
|
73
|
+
- - "~>"
|
74
|
+
- !ruby/object:Gem::Version
|
75
|
+
version: '4.1'
|
76
|
+
type: :development
|
77
|
+
prerelease: false
|
78
|
+
version_requirements: !ruby/object:Gem::Requirement
|
79
|
+
requirements:
|
80
|
+
- - "~>"
|
81
|
+
- !ruby/object:Gem::Version
|
82
|
+
version: '4.1'
|
83
|
+
- !ruby/object:Gem::Dependency
|
84
|
+
name: test-unit
|
85
|
+
requirement: !ruby/object:Gem::Requirement
|
86
|
+
requirements:
|
87
|
+
- - "~>"
|
88
|
+
- !ruby/object:Gem::Version
|
89
|
+
version: '3.2'
|
90
|
+
type: :development
|
91
|
+
prerelease: false
|
92
|
+
version_requirements: !ruby/object:Gem::Requirement
|
93
|
+
requirements:
|
94
|
+
- - "~>"
|
95
|
+
- !ruby/object:Gem::Version
|
96
|
+
version: '3.2'
|
97
|
+
- !ruby/object:Gem::Dependency
|
98
|
+
name: sass-rails
|
99
|
+
requirement: !ruby/object:Gem::Requirement
|
100
|
+
requirements:
|
101
|
+
- - "~>"
|
102
|
+
- !ruby/object:Gem::Version
|
103
|
+
version: '5.0'
|
104
|
+
type: :development
|
105
|
+
prerelease: false
|
106
|
+
version_requirements: !ruby/object:Gem::Requirement
|
107
|
+
requirements:
|
108
|
+
- - "~>"
|
109
|
+
- !ruby/object:Gem::Version
|
110
|
+
version: '5.0'
|
111
|
+
- !ruby/object:Gem::Dependency
|
112
|
+
name: poltergeist
|
113
|
+
requirement: !ruby/object:Gem::Requirement
|
114
|
+
requirements:
|
115
|
+
- - "~>"
|
116
|
+
- !ruby/object:Gem::Version
|
117
|
+
version: '1.10'
|
118
|
+
type: :development
|
119
|
+
prerelease: false
|
120
|
+
version_requirements: !ruby/object:Gem::Requirement
|
121
|
+
requirements:
|
122
|
+
- - "~>"
|
123
|
+
- !ruby/object:Gem::Version
|
124
|
+
version: '1.10'
|
125
|
+
- !ruby/object:Gem::Dependency
|
126
|
+
name: rake
|
127
|
+
requirement: !ruby/object:Gem::Requirement
|
128
|
+
requirements:
|
129
|
+
- - "~>"
|
130
|
+
- !ruby/object:Gem::Version
|
131
|
+
version: '11.2'
|
132
|
+
type: :development
|
133
|
+
prerelease: false
|
134
|
+
version_requirements: !ruby/object:Gem::Requirement
|
135
|
+
requirements:
|
136
|
+
- - "~>"
|
137
|
+
- !ruby/object:Gem::Version
|
138
|
+
version: '11.2'
|
139
|
+
- !ruby/object:Gem::Dependency
|
140
|
+
name: turbolinks
|
141
|
+
requirement: !ruby/object:Gem::Requirement
|
142
|
+
requirements:
|
143
|
+
- - "~>"
|
144
|
+
- !ruby/object:Gem::Version
|
145
|
+
version: '5.0'
|
146
|
+
type: :development
|
147
|
+
prerelease: false
|
148
|
+
version_requirements: !ruby/object:Gem::Requirement
|
149
|
+
requirements:
|
150
|
+
- - "~>"
|
151
|
+
- !ruby/object:Gem::Version
|
152
|
+
version: '5.0'
|
153
|
+
description: Replace rail's built in link_to/submit/button with confirmations with
|
154
|
+
SweetAlert2 confirmations
|
155
|
+
email:
|
156
|
+
- j@joewoodward.me
|
157
|
+
executables: []
|
158
|
+
extensions: []
|
159
|
+
extra_rdoc_files: []
|
160
|
+
files:
|
161
|
+
- ".gitignore"
|
162
|
+
- ".travis.yml"
|
163
|
+
- Gemfile
|
164
|
+
- MIT-LICENSE
|
165
|
+
- README.md
|
166
|
+
- Rakefile
|
167
|
+
- lib/assets/javascripts/rails_sweetalert2_confirm.js
|
168
|
+
- lib/rails_sweetalert2_confirm.rb
|
169
|
+
- lib/rails_sweetalert2_confirm/rails/engine.rb
|
170
|
+
- lib/rails_sweetalert2_confirm/railtie.rb
|
171
|
+
- lib/rails_sweetalert2_confirm/version.rb
|
172
|
+
- lib/rails_sweetalert2_confirm/view_helpers.rb
|
173
|
+
- rails_sweetalert2_confirm.gemspec
|
174
|
+
- spec/dummy/.gitignore
|
175
|
+
- spec/dummy/.rspec
|
176
|
+
- spec/dummy/Rakefile
|
177
|
+
- spec/dummy/app/assets/javascripts/application.js
|
178
|
+
- spec/dummy/app/assets/javascripts/application_turbolinks.js
|
179
|
+
- spec/dummy/app/assets/stylesheets/application.css
|
180
|
+
- spec/dummy/app/controllers/application_controller.rb
|
181
|
+
- spec/dummy/app/views/application/destroy.html.erb
|
182
|
+
- spec/dummy/app/views/application/destroy.js.erb
|
183
|
+
- spec/dummy/app/views/application/index.html.erb
|
184
|
+
- spec/dummy/app/views/layouts/application.html.erb
|
185
|
+
- spec/dummy/bin/bundle
|
186
|
+
- spec/dummy/bin/rails
|
187
|
+
- spec/dummy/bin/rake
|
188
|
+
- spec/dummy/config.ru
|
189
|
+
- spec/dummy/config/application.rb
|
190
|
+
- spec/dummy/config/boot.rb
|
191
|
+
- spec/dummy/config/database.yml
|
192
|
+
- spec/dummy/config/environment.rb
|
193
|
+
- spec/dummy/config/environments/development.rb
|
194
|
+
- spec/dummy/config/environments/production.rb
|
195
|
+
- spec/dummy/config/environments/test.rb
|
196
|
+
- spec/dummy/config/initializers/assets.rb
|
197
|
+
- spec/dummy/config/initializers/backtrace_silencers.rb
|
198
|
+
- spec/dummy/config/initializers/cookies_serializer.rb
|
199
|
+
- spec/dummy/config/initializers/filter_parameter_logging.rb
|
200
|
+
- spec/dummy/config/initializers/inflections.rb
|
201
|
+
- spec/dummy/config/initializers/mime_types.rb
|
202
|
+
- spec/dummy/config/initializers/secret_token.rb
|
203
|
+
- spec/dummy/config/initializers/session_store.rb
|
204
|
+
- spec/dummy/config/initializers/wrap_parameters.rb
|
205
|
+
- spec/dummy/config/locales/en.yml
|
206
|
+
- spec/dummy/config/routes.rb
|
207
|
+
- spec/dummy/config/secrets.yml
|
208
|
+
- spec/dummy/log/.keep
|
209
|
+
- spec/dummy/public/404.html
|
210
|
+
- spec/dummy/public/422.html
|
211
|
+
- spec/dummy/public/500.html
|
212
|
+
- spec/dummy/public/favicon.ico
|
213
|
+
- spec/features/rails_sweetalert2_confirm_spec.rb
|
214
|
+
- spec/spec_helper.rb
|
215
|
+
- tags
|
216
|
+
homepage: https://github.com/JoeWoodward/rails-sweetalert2-confirm
|
217
|
+
licenses:
|
218
|
+
- MIT
|
219
|
+
metadata: {}
|
220
|
+
post_install_message:
|
221
|
+
rdoc_options: []
|
222
|
+
require_paths:
|
223
|
+
- lib
|
224
|
+
required_ruby_version: !ruby/object:Gem::Requirement
|
225
|
+
requirements:
|
226
|
+
- - ">="
|
227
|
+
- !ruby/object:Gem::Version
|
228
|
+
version: '0'
|
229
|
+
required_rubygems_version: !ruby/object:Gem::Requirement
|
230
|
+
requirements:
|
231
|
+
- - ">="
|
232
|
+
- !ruby/object:Gem::Version
|
233
|
+
version: '0'
|
234
|
+
requirements: []
|
235
|
+
rubyforge_project:
|
236
|
+
rubygems_version: 2.4.5
|
237
|
+
signing_key:
|
238
|
+
specification_version: 4
|
239
|
+
summary: A Rails Confirm Replacement Using SweetAlert2
|
240
|
+
test_files: []
|
241
|
+
has_rdoc:
|