formtastic 5.0.0 → 6.0.0.alpha
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 +4 -4
- data/.github/workflows/integration.yaml +36 -0
- data/.github/workflows/test.yml +26 -20
- data/.gitignore +2 -1
- data/Appraisals +23 -0
- data/CHANGELOG.md +18 -0
- data/CONTRIBUTING.md +27 -0
- data/Gemfile +5 -0
- data/MIT-LICENSE +1 -1
- data/README.md +9 -41
- data/Rakefile +1 -1
- data/formtastic.gemspec +17 -10
- data/gemfiles/rails_72.gemfile +9 -0
- data/gemfiles/rails_80.gemfile +9 -0
- data/gemfiles/rails_81.gemfile +9 -0
- data/gemfiles/rails_edge.gemfile +9 -0
- data/lib/formtastic/form_builder.rb +25 -25
- data/lib/formtastic/helpers/action_helper.rb +0 -1
- data/lib/formtastic/helpers/errors_helper.rb +71 -14
- data/lib/formtastic/helpers/input_helper.rb +4 -2
- data/lib/formtastic/i18n.rb +0 -1
- data/lib/formtastic/inputs/base/aria.rb +26 -0
- data/lib/formtastic/inputs/base/collections.rb +1 -1
- data/lib/formtastic/inputs/base/errors.rb +1 -1
- data/lib/formtastic/inputs/base/html.rb +1 -1
- data/lib/formtastic/inputs/base/labelling.rb +1 -1
- data/lib/formtastic/inputs/base/validations.rb +32 -8
- data/lib/formtastic/inputs/base.rb +4 -2
- data/lib/formtastic/inputs/country_input.rb +9 -6
- data/lib/formtastic/version.rb +1 -1
- data/lib/formtastic.rb +6 -2
- data/lib/generators/formtastic/form/form_generator.rb +2 -3
- data/lib/generators/formtastic/install/install_generator.rb +0 -1
- data/lib/generators/formtastic/stylesheets/stylesheets_generator.rb +15 -0
- data/{app/assets/stylesheets → lib/generators/templates}/formtastic.css +4 -4
- data/lib/generators/templates/formtastic.rb +7 -1
- data/script/integration-template.rb +14 -11
- data/script/integration.sh +17 -4
- data/spec/action_class_finder_spec.rb +0 -1
- data/spec/actions/button_action_spec.rb +0 -1
- data/spec/actions/generic_action_spec.rb +0 -1
- data/spec/actions/input_action_spec.rb +0 -1
- data/spec/actions/link_action_spec.rb +0 -1
- data/spec/builder/custom_builder_spec.rb +0 -1
- data/spec/builder/error_proc_spec.rb +0 -1
- data/spec/builder/semantic_fields_for_spec.rb +72 -2
- data/spec/fast_spec_helper.rb +0 -1
- data/spec/generators/formtastic/stylesheets/stylesheets_generator_spec.rb +22 -0
- data/spec/helpers/actions_helper_spec.rb +0 -1
- data/spec/helpers/form_helper_spec.rb +0 -1
- data/spec/helpers/input_helper_spec.rb +12 -1
- data/spec/helpers/inputs_helper_spec.rb +0 -1
- data/spec/helpers/reflection_helper_spec.rb +0 -1
- data/spec/helpers/semantic_errors_helper_spec.rb +114 -7
- data/spec/i18n_spec.rb +0 -1
- data/spec/input_class_finder_spec.rb +0 -1
- data/spec/inputs/base/collections_spec.rb +41 -0
- data/spec/inputs/boolean_input_spec.rb +0 -1
- data/spec/inputs/check_boxes_input_spec.rb +1 -2
- data/spec/inputs/color_input_spec.rb +0 -1
- data/spec/inputs/country_input_spec.rb +5 -6
- data/spec/inputs/custom_input_spec.rb +0 -1
- data/spec/inputs/datalist_input_spec.rb +0 -1
- data/spec/inputs/date_picker_input_spec.rb +0 -1
- data/spec/inputs/date_select_input_spec.rb +1 -2
- data/spec/inputs/datetime_picker_input_spec.rb +0 -1
- data/spec/inputs/datetime_select_input_spec.rb +1 -2
- data/spec/inputs/email_input_spec.rb +0 -1
- data/spec/inputs/file_input_spec.rb +0 -1
- data/spec/inputs/hidden_input_spec.rb +0 -1
- data/spec/inputs/include_blank_spec.rb +0 -1
- data/spec/inputs/label_spec.rb +32 -1
- data/spec/inputs/number_input_spec.rb +0 -1
- data/spec/inputs/password_input_spec.rb +1 -2
- data/spec/inputs/phone_input_spec.rb +0 -1
- data/spec/inputs/placeholder_spec.rb +0 -1
- data/spec/inputs/radio_input_spec.rb +0 -1
- data/spec/inputs/range_input_spec.rb +0 -1
- data/spec/inputs/readonly_spec.rb +0 -1
- data/spec/inputs/search_input_spec.rb +0 -1
- data/spec/inputs/select_input_spec.rb +0 -1
- data/spec/inputs/string_input_spec.rb +67 -2
- data/spec/inputs/text_input_spec.rb +0 -1
- data/spec/inputs/time_picker_input_spec.rb +0 -1
- data/spec/inputs/time_select_input_spec.rb +1 -2
- data/spec/inputs/time_zone_input_spec.rb +0 -1
- data/spec/inputs/url_input_spec.rb +0 -1
- data/spec/inputs/with_options_spec.rb +0 -1
- data/spec/localizer_spec.rb +0 -1
- data/spec/namespaced_class_finder_spec.rb +0 -1
- data/spec/spec_helper.rb +2 -1
- data/spec/support/custom_macros.rb +11 -3
- data/spec/support/specialized_class_finder_shared_example.rb +0 -1
- data/spec/support/test_environment.rb +1 -1
- metadata +53 -40
- data/Gemfile.lock +0 -140
- data/app/assets/stylesheets/formtastic_ie6.css +0 -33
- data/app/assets/stylesheets/formtastic_ie7.css +0 -23
- data/gemfiles/rails_6.0/Gemfile +0 -5
- data/gemfiles/rails_6.1/Gemfile +0 -5
- data/gemfiles/rails_7.0/Gemfile +0 -5
- data/gemfiles/rails_7.1/Gemfile +0 -5
- data/gemfiles/rails_edge/Gemfile +0 -13
- data/lib/formtastic/engine.rb +0 -14
data/spec/spec_helper.rb
CHANGED
|
@@ -1,4 +1,3 @@
|
|
|
1
|
-
# encoding: utf-8
|
|
2
1
|
# frozen_string_literal: true
|
|
3
2
|
require 'rubygems'
|
|
4
3
|
require 'bundler/setup'
|
|
@@ -365,6 +364,7 @@ module FormtasticSpecHelper
|
|
|
365
364
|
end
|
|
366
365
|
|
|
367
366
|
allow(@new_post).to receive(:title)
|
|
367
|
+
allow(@new_post).to receive(:status)
|
|
368
368
|
allow(@new_post).to receive(:email)
|
|
369
369
|
allow(@new_post).to receive(:url)
|
|
370
370
|
allow(@new_post).to receive(:phone)
|
|
@@ -390,6 +390,7 @@ module FormtasticSpecHelper
|
|
|
390
390
|
allow(@new_post).to receive(:document).and_return(@mock_file)
|
|
391
391
|
allow(@new_post).to receive(:column_for_attribute).with(:meta_description).and_return(double('column', :type => :string, :limit => 255))
|
|
392
392
|
allow(@new_post).to receive(:column_for_attribute).with(:title).and_return(double('column', :type => :string, :limit => 50))
|
|
393
|
+
allow(@new_post).to receive(:column_for_attribute).with(:status).and_return(double('column', :type => :integer, :limit => 1))
|
|
393
394
|
allow(@new_post).to receive(:column_for_attribute).with(:body).and_return(double('column', :type => :text))
|
|
394
395
|
allow(@new_post).to receive(:column_for_attribute).with(:published).and_return(double('column', :type => :boolean))
|
|
395
396
|
allow(@new_post).to receive(:column_for_attribute).with(:publish_at).and_return(double('column', :type => :date))
|
|
@@ -1,4 +1,3 @@
|
|
|
1
|
-
# encoding: utf-8
|
|
2
1
|
# frozen_string_literal: true
|
|
3
2
|
|
|
4
3
|
module CustomMacros
|
|
@@ -171,13 +170,22 @@ module CustomMacros
|
|
|
171
170
|
end
|
|
172
171
|
end
|
|
173
172
|
|
|
174
|
-
def
|
|
173
|
+
def it_should_have_maxlength_matching_string_column_limit
|
|
175
174
|
it 'should have a maxlength matching column limit' do
|
|
175
|
+
expect(@new_post.column_for_attribute(:title).type).to eq(:string)
|
|
176
176
|
expect(@new_post.column_for_attribute(:title).limit).to eq(50)
|
|
177
177
|
expect(output_buffer.to_str).to have_tag("form li input[@maxlength='50']")
|
|
178
178
|
end
|
|
179
179
|
end
|
|
180
180
|
|
|
181
|
+
def it_should_have_maxlength_matching_integer_column_limit
|
|
182
|
+
it 'should have a maxlength matching column limit' do
|
|
183
|
+
expect(@new_post.column_for_attribute(:status).type).to eq(:integer)
|
|
184
|
+
expect(@new_post.column_for_attribute(:status).limit).to eq(1)
|
|
185
|
+
expect(output_buffer.to_str).to have_tag("form li input[@maxlength='3']")
|
|
186
|
+
end
|
|
187
|
+
end
|
|
188
|
+
|
|
181
189
|
def it_should_use_column_size_for_columns_shorter_than_default_text_field_size(as)
|
|
182
190
|
it 'should use the column size for columns shorter than default_text_field_size' do
|
|
183
191
|
column_limit_shorted_than_default = 1
|
|
@@ -406,7 +414,7 @@ module CustomMacros
|
|
|
406
414
|
|
|
407
415
|
describe 'and the :collection is an OrderedHash of strings' do
|
|
408
416
|
before do
|
|
409
|
-
@categories = ActiveSupport::OrderedHash
|
|
417
|
+
@categories = ActiveSupport::OrderedHash['General' => 'gen', 'Design' => 'des','Development' => 'dev']
|
|
410
418
|
end
|
|
411
419
|
|
|
412
420
|
it "should use the key as the label text and the hash value as the value attribute for each #{countable}" do
|
|
@@ -1,4 +1,3 @@
|
|
|
1
|
-
# encoding: utf-8
|
|
2
1
|
# frozen_string_literal: true
|
|
3
2
|
require 'rspec/core'
|
|
4
3
|
|
|
@@ -39,6 +38,7 @@ module FormtasticTest
|
|
|
39
38
|
config.active_support.deprecation = :stderr
|
|
40
39
|
config.secret_key_base = "secret"
|
|
41
40
|
config.eager_load = false
|
|
41
|
+
config.active_support.to_time_preserves_timezone = :zone
|
|
42
42
|
end
|
|
43
43
|
end
|
|
44
44
|
FormtasticTest::Application.initialize!
|
metadata
CHANGED
|
@@ -1,14 +1,13 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: formtastic
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version:
|
|
4
|
+
version: 6.0.0.alpha
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Justin French
|
|
8
|
-
autorequire:
|
|
9
8
|
bindir: bin
|
|
10
9
|
cert_chain: []
|
|
11
|
-
date:
|
|
10
|
+
date: 1980-01-02 00:00:00.000000000 Z
|
|
12
11
|
dependencies:
|
|
13
12
|
- !ruby/object:Gem::Dependency
|
|
14
13
|
name: actionpack
|
|
@@ -16,84 +15,98 @@ dependencies:
|
|
|
16
15
|
requirements:
|
|
17
16
|
- - ">="
|
|
18
17
|
- !ruby/object:Gem::Version
|
|
19
|
-
version:
|
|
18
|
+
version: 7.2.0
|
|
20
19
|
type: :runtime
|
|
21
20
|
prerelease: false
|
|
22
21
|
version_requirements: !ruby/object:Gem::Requirement
|
|
23
22
|
requirements:
|
|
24
23
|
- - ">="
|
|
25
24
|
- !ruby/object:Gem::Version
|
|
26
|
-
version:
|
|
25
|
+
version: 7.2.0
|
|
26
|
+
- !ruby/object:Gem::Dependency
|
|
27
|
+
name: appraisal
|
|
28
|
+
requirement: !ruby/object:Gem::Requirement
|
|
29
|
+
requirements:
|
|
30
|
+
- - ">="
|
|
31
|
+
- !ruby/object:Gem::Version
|
|
32
|
+
version: '0'
|
|
33
|
+
type: :development
|
|
34
|
+
prerelease: false
|
|
35
|
+
version_requirements: !ruby/object:Gem::Requirement
|
|
36
|
+
requirements:
|
|
37
|
+
- - ">="
|
|
38
|
+
- !ruby/object:Gem::Version
|
|
39
|
+
version: '0'
|
|
27
40
|
- !ruby/object:Gem::Dependency
|
|
28
41
|
name: rspec-rails
|
|
29
42
|
requirement: !ruby/object:Gem::Requirement
|
|
30
43
|
requirements:
|
|
31
44
|
- - ">="
|
|
32
45
|
- !ruby/object:Gem::Version
|
|
33
|
-
version: '
|
|
46
|
+
version: '0'
|
|
34
47
|
type: :development
|
|
35
48
|
prerelease: false
|
|
36
49
|
version_requirements: !ruby/object:Gem::Requirement
|
|
37
50
|
requirements:
|
|
38
51
|
- - ">="
|
|
39
52
|
- !ruby/object:Gem::Version
|
|
40
|
-
version: '
|
|
53
|
+
version: '0'
|
|
41
54
|
- !ruby/object:Gem::Dependency
|
|
42
55
|
name: rspec-dom-testing
|
|
43
56
|
requirement: !ruby/object:Gem::Requirement
|
|
44
57
|
requirements:
|
|
45
58
|
- - ">="
|
|
46
59
|
- !ruby/object:Gem::Version
|
|
47
|
-
version: 0
|
|
60
|
+
version: '0'
|
|
48
61
|
type: :development
|
|
49
62
|
prerelease: false
|
|
50
63
|
version_requirements: !ruby/object:Gem::Requirement
|
|
51
64
|
requirements:
|
|
52
65
|
- - ">="
|
|
53
66
|
- !ruby/object:Gem::Version
|
|
54
|
-
version: 0
|
|
67
|
+
version: '0'
|
|
55
68
|
- !ruby/object:Gem::Dependency
|
|
56
69
|
name: rspec-mocks
|
|
57
70
|
requirement: !ruby/object:Gem::Requirement
|
|
58
71
|
requirements:
|
|
59
|
-
- - "
|
|
72
|
+
- - ">="
|
|
60
73
|
- !ruby/object:Gem::Version
|
|
61
|
-
version:
|
|
74
|
+
version: '0'
|
|
62
75
|
type: :development
|
|
63
76
|
prerelease: false
|
|
64
77
|
version_requirements: !ruby/object:Gem::Requirement
|
|
65
78
|
requirements:
|
|
66
|
-
- - "
|
|
79
|
+
- - ">="
|
|
67
80
|
- !ruby/object:Gem::Version
|
|
68
|
-
version:
|
|
81
|
+
version: '0'
|
|
69
82
|
- !ruby/object:Gem::Dependency
|
|
70
83
|
name: yard
|
|
71
84
|
requirement: !ruby/object:Gem::Requirement
|
|
72
85
|
requirements:
|
|
73
|
-
- - "
|
|
86
|
+
- - ">="
|
|
74
87
|
- !ruby/object:Gem::Version
|
|
75
|
-
version: 0
|
|
88
|
+
version: '0'
|
|
76
89
|
type: :development
|
|
77
90
|
prerelease: false
|
|
78
91
|
version_requirements: !ruby/object:Gem::Requirement
|
|
79
92
|
requirements:
|
|
80
|
-
- - "
|
|
93
|
+
- - ">="
|
|
81
94
|
- !ruby/object:Gem::Version
|
|
82
|
-
version: 0
|
|
95
|
+
version: '0'
|
|
83
96
|
- !ruby/object:Gem::Dependency
|
|
84
97
|
name: ammeter
|
|
85
98
|
requirement: !ruby/object:Gem::Requirement
|
|
86
99
|
requirements:
|
|
87
|
-
- - "
|
|
100
|
+
- - ">="
|
|
88
101
|
- !ruby/object:Gem::Version
|
|
89
|
-
version:
|
|
102
|
+
version: '0'
|
|
90
103
|
type: :development
|
|
91
104
|
prerelease: false
|
|
92
105
|
version_requirements: !ruby/object:Gem::Requirement
|
|
93
106
|
requirements:
|
|
94
|
-
- - "
|
|
107
|
+
- - ">="
|
|
95
108
|
- !ruby/object:Gem::Version
|
|
96
|
-
version:
|
|
109
|
+
version: '0'
|
|
97
110
|
- !ruby/object:Gem::Dependency
|
|
98
111
|
name: rake
|
|
99
112
|
requirement: !ruby/object:Gem::Requirement
|
|
@@ -112,16 +125,16 @@ dependencies:
|
|
|
112
125
|
name: sqlite3
|
|
113
126
|
requirement: !ruby/object:Gem::Requirement
|
|
114
127
|
requirements:
|
|
115
|
-
- - "
|
|
128
|
+
- - ">="
|
|
116
129
|
- !ruby/object:Gem::Version
|
|
117
|
-
version: '
|
|
130
|
+
version: '0'
|
|
118
131
|
type: :development
|
|
119
132
|
prerelease: false
|
|
120
133
|
version_requirements: !ruby/object:Gem::Requirement
|
|
121
134
|
requirements:
|
|
122
|
-
- - "
|
|
135
|
+
- - ">="
|
|
123
136
|
- !ruby/object:Gem::Version
|
|
124
|
-
version: '
|
|
137
|
+
version: '0'
|
|
125
138
|
description: A Rails form builder plugin/gem with semantically rich and accessible
|
|
126
139
|
markup
|
|
127
140
|
email:
|
|
@@ -132,27 +145,25 @@ extra_rdoc_files:
|
|
|
132
145
|
- README.md
|
|
133
146
|
files:
|
|
134
147
|
- ".gitattributes"
|
|
148
|
+
- ".github/workflows/integration.yaml"
|
|
135
149
|
- ".github/workflows/test.yml"
|
|
136
150
|
- ".gitignore"
|
|
137
151
|
- ".rspec"
|
|
138
152
|
- ".yardopts"
|
|
153
|
+
- Appraisals
|
|
139
154
|
- CHANGELOG.md
|
|
155
|
+
- CONTRIBUTING.md
|
|
140
156
|
- Gemfile
|
|
141
|
-
- Gemfile.lock
|
|
142
157
|
- MIT-LICENSE
|
|
143
158
|
- README.md
|
|
144
159
|
- RELEASE_PROCESS
|
|
145
160
|
- Rakefile
|
|
146
|
-
- app/assets/stylesheets/formtastic.css
|
|
147
|
-
- app/assets/stylesheets/formtastic_ie6.css
|
|
148
|
-
- app/assets/stylesheets/formtastic_ie7.css
|
|
149
161
|
- bin/appraisal
|
|
150
162
|
- formtastic.gemspec
|
|
151
|
-
- gemfiles/
|
|
152
|
-
- gemfiles/
|
|
153
|
-
- gemfiles/
|
|
154
|
-
- gemfiles/
|
|
155
|
-
- gemfiles/rails_edge/Gemfile
|
|
163
|
+
- gemfiles/rails_72.gemfile
|
|
164
|
+
- gemfiles/rails_80.gemfile
|
|
165
|
+
- gemfiles/rails_81.gemfile
|
|
166
|
+
- gemfiles/rails_edge.gemfile
|
|
156
167
|
- lib/formtastic.rb
|
|
157
168
|
- lib/formtastic/action_class_finder.rb
|
|
158
169
|
- lib/formtastic/actions.rb
|
|
@@ -162,7 +173,6 @@ files:
|
|
|
162
173
|
- lib/formtastic/actions/input_action.rb
|
|
163
174
|
- lib/formtastic/actions/link_action.rb
|
|
164
175
|
- lib/formtastic/deprecation.rb
|
|
165
|
-
- lib/formtastic/engine.rb
|
|
166
176
|
- lib/formtastic/form_builder.rb
|
|
167
177
|
- lib/formtastic/helpers.rb
|
|
168
178
|
- lib/formtastic/helpers/action_helper.rb
|
|
@@ -180,6 +190,7 @@ files:
|
|
|
180
190
|
- lib/formtastic/input_class_finder.rb
|
|
181
191
|
- lib/formtastic/inputs.rb
|
|
182
192
|
- lib/formtastic/inputs/base.rb
|
|
193
|
+
- lib/formtastic/inputs/base/aria.rb
|
|
183
194
|
- lib/formtastic/inputs/base/associations.rb
|
|
184
195
|
- lib/formtastic/inputs/base/choices.rb
|
|
185
196
|
- lib/formtastic/inputs/base/collections.rb
|
|
@@ -230,9 +241,11 @@ files:
|
|
|
230
241
|
- lib/generators/formtastic/form/form_generator.rb
|
|
231
242
|
- lib/generators/formtastic/input/input_generator.rb
|
|
232
243
|
- lib/generators/formtastic/install/install_generator.rb
|
|
244
|
+
- lib/generators/formtastic/stylesheets/stylesheets_generator.rb
|
|
233
245
|
- lib/generators/templates/_form.html.erb
|
|
234
246
|
- lib/generators/templates/_form.html.haml
|
|
235
247
|
- lib/generators/templates/_form.html.slim
|
|
248
|
+
- lib/generators/templates/formtastic.css
|
|
236
249
|
- lib/generators/templates/formtastic.rb
|
|
237
250
|
- lib/generators/templates/input.rb
|
|
238
251
|
- lib/locale/en.yml
|
|
@@ -253,6 +266,7 @@ files:
|
|
|
253
266
|
- spec/generators/formtastic/form/form_generator_spec.rb
|
|
254
267
|
- spec/generators/formtastic/input/input_generator_spec.rb
|
|
255
268
|
- spec/generators/formtastic/install/install_generator_spec.rb
|
|
269
|
+
- spec/generators/formtastic/stylesheets/stylesheets_generator_spec.rb
|
|
256
270
|
- spec/helpers/action_helper_spec.rb
|
|
257
271
|
- spec/helpers/actions_helper_spec.rb
|
|
258
272
|
- spec/helpers/form_helper_spec.rb
|
|
@@ -309,7 +323,6 @@ homepage: http://github.com/formtastic/formtastic
|
|
|
309
323
|
licenses:
|
|
310
324
|
- MIT
|
|
311
325
|
metadata: {}
|
|
312
|
-
post_install_message:
|
|
313
326
|
rdoc_options:
|
|
314
327
|
- "--charset=UTF-8"
|
|
315
328
|
require_paths:
|
|
@@ -318,15 +331,14 @@ required_ruby_version: !ruby/object:Gem::Requirement
|
|
|
318
331
|
requirements:
|
|
319
332
|
- - ">="
|
|
320
333
|
- !ruby/object:Gem::Version
|
|
321
|
-
version:
|
|
334
|
+
version: 3.1.0
|
|
322
335
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
|
323
336
|
requirements:
|
|
324
337
|
- - ">="
|
|
325
338
|
- !ruby/object:Gem::Version
|
|
326
|
-
version:
|
|
339
|
+
version: 1.8.11
|
|
327
340
|
requirements: []
|
|
328
|
-
rubygems_version: 3.
|
|
329
|
-
signing_key:
|
|
341
|
+
rubygems_version: 3.6.8
|
|
330
342
|
specification_version: 4
|
|
331
343
|
summary: A Rails form builder plugin/gem with semantically rich and accessible markup
|
|
332
344
|
test_files:
|
|
@@ -342,6 +354,7 @@ test_files:
|
|
|
342
354
|
- spec/generators/formtastic/form/form_generator_spec.rb
|
|
343
355
|
- spec/generators/formtastic/input/input_generator_spec.rb
|
|
344
356
|
- spec/generators/formtastic/install/install_generator_spec.rb
|
|
357
|
+
- spec/generators/formtastic/stylesheets/stylesheets_generator_spec.rb
|
|
345
358
|
- spec/helpers/action_helper_spec.rb
|
|
346
359
|
- spec/helpers/actions_helper_spec.rb
|
|
347
360
|
- spec/helpers/form_helper_spec.rb
|
data/Gemfile.lock
DELETED
|
@@ -1,140 +0,0 @@
|
|
|
1
|
-
PATH
|
|
2
|
-
remote: .
|
|
3
|
-
specs:
|
|
4
|
-
formtastic (4.0.0)
|
|
5
|
-
actionpack (>= 6.0.0)
|
|
6
|
-
|
|
7
|
-
GEM
|
|
8
|
-
remote: https://rubygems.org/
|
|
9
|
-
specs:
|
|
10
|
-
actionpack (7.1.1)
|
|
11
|
-
actionview (= 7.1.1)
|
|
12
|
-
activesupport (= 7.1.1)
|
|
13
|
-
nokogiri (>= 1.8.5)
|
|
14
|
-
rack (>= 2.2.4)
|
|
15
|
-
rack-session (>= 1.0.1)
|
|
16
|
-
rack-test (>= 0.6.3)
|
|
17
|
-
rails-dom-testing (~> 2.2)
|
|
18
|
-
rails-html-sanitizer (~> 1.6)
|
|
19
|
-
actionview (7.1.1)
|
|
20
|
-
activesupport (= 7.1.1)
|
|
21
|
-
builder (~> 3.1)
|
|
22
|
-
erubi (~> 1.11)
|
|
23
|
-
rails-dom-testing (~> 2.2)
|
|
24
|
-
rails-html-sanitizer (~> 1.6)
|
|
25
|
-
activesupport (7.1.1)
|
|
26
|
-
base64
|
|
27
|
-
bigdecimal
|
|
28
|
-
concurrent-ruby (~> 1.0, >= 1.0.2)
|
|
29
|
-
connection_pool (>= 2.2.5)
|
|
30
|
-
drb
|
|
31
|
-
i18n (>= 1.6, < 2)
|
|
32
|
-
minitest (>= 5.1)
|
|
33
|
-
mutex_m
|
|
34
|
-
tzinfo (~> 2.0)
|
|
35
|
-
ammeter (1.1.5)
|
|
36
|
-
activesupport (>= 3.0)
|
|
37
|
-
railties (>= 3.0)
|
|
38
|
-
rspec-rails (>= 2.2)
|
|
39
|
-
base64 (0.1.1)
|
|
40
|
-
bigdecimal (3.1.4)
|
|
41
|
-
builder (3.2.4)
|
|
42
|
-
concurrent-ruby (1.2.2)
|
|
43
|
-
connection_pool (2.4.1)
|
|
44
|
-
crass (1.0.6)
|
|
45
|
-
diff-lcs (1.5.0)
|
|
46
|
-
drb (2.1.1)
|
|
47
|
-
ruby2_keywords
|
|
48
|
-
erubi (1.12.0)
|
|
49
|
-
i18n (1.14.1)
|
|
50
|
-
concurrent-ruby (~> 1.0)
|
|
51
|
-
io-console (0.6.0)
|
|
52
|
-
irb (1.8.1)
|
|
53
|
-
rdoc
|
|
54
|
-
reline (>= 0.3.8)
|
|
55
|
-
loofah (2.21.4)
|
|
56
|
-
crass (~> 1.0.2)
|
|
57
|
-
nokogiri (>= 1.12.0)
|
|
58
|
-
mini_portile2 (2.8.4)
|
|
59
|
-
minitest (5.20.0)
|
|
60
|
-
mutex_m (0.1.2)
|
|
61
|
-
nokogiri (1.15.4)
|
|
62
|
-
mini_portile2 (~> 2.8.2)
|
|
63
|
-
racc (~> 1.4)
|
|
64
|
-
psych (5.1.1)
|
|
65
|
-
stringio
|
|
66
|
-
racc (1.7.1)
|
|
67
|
-
rack (3.0.8)
|
|
68
|
-
rack-session (2.0.0)
|
|
69
|
-
rack (>= 3.0.0)
|
|
70
|
-
rack-test (2.1.0)
|
|
71
|
-
rack (>= 1.3)
|
|
72
|
-
rackup (2.1.0)
|
|
73
|
-
rack (>= 3)
|
|
74
|
-
webrick (~> 1.8)
|
|
75
|
-
rails-dom-testing (2.2.0)
|
|
76
|
-
activesupport (>= 5.0.0)
|
|
77
|
-
minitest
|
|
78
|
-
nokogiri (>= 1.6)
|
|
79
|
-
rails-html-sanitizer (1.6.0)
|
|
80
|
-
loofah (~> 2.21)
|
|
81
|
-
nokogiri (~> 1.14)
|
|
82
|
-
railties (7.1.1)
|
|
83
|
-
actionpack (= 7.1.1)
|
|
84
|
-
activesupport (= 7.1.1)
|
|
85
|
-
irb
|
|
86
|
-
rackup (>= 1.0.0)
|
|
87
|
-
rake (>= 12.2)
|
|
88
|
-
thor (~> 1.0, >= 1.2.2)
|
|
89
|
-
zeitwerk (~> 2.6)
|
|
90
|
-
rake (13.0.6)
|
|
91
|
-
rdoc (6.5.0)
|
|
92
|
-
psych (>= 4.0.0)
|
|
93
|
-
reline (0.3.9)
|
|
94
|
-
io-console (~> 0.5)
|
|
95
|
-
rspec-core (3.12.2)
|
|
96
|
-
rspec-support (~> 3.12.0)
|
|
97
|
-
rspec-dom-testing (0.1.0)
|
|
98
|
-
rails-dom-testing (>= 1.0, < 3)
|
|
99
|
-
rspec-expectations (~> 3.0)
|
|
100
|
-
rspec-expectations (3.12.3)
|
|
101
|
-
diff-lcs (>= 1.2.0, < 2.0)
|
|
102
|
-
rspec-support (~> 3.12.0)
|
|
103
|
-
rspec-mocks (3.12.6)
|
|
104
|
-
diff-lcs (>= 1.2.0, < 2.0)
|
|
105
|
-
rspec-support (~> 3.12.0)
|
|
106
|
-
rspec-rails (6.0.3)
|
|
107
|
-
actionpack (>= 6.1)
|
|
108
|
-
activesupport (>= 6.1)
|
|
109
|
-
railties (>= 6.1)
|
|
110
|
-
rspec-core (~> 3.12)
|
|
111
|
-
rspec-expectations (~> 3.12)
|
|
112
|
-
rspec-mocks (~> 3.12)
|
|
113
|
-
rspec-support (~> 3.12)
|
|
114
|
-
rspec-support (3.12.1)
|
|
115
|
-
ruby2_keywords (0.0.5)
|
|
116
|
-
sqlite3 (1.6.7)
|
|
117
|
-
mini_portile2 (~> 2.8.0)
|
|
118
|
-
stringio (3.0.8)
|
|
119
|
-
thor (1.2.2)
|
|
120
|
-
tzinfo (2.0.6)
|
|
121
|
-
concurrent-ruby (~> 1.0)
|
|
122
|
-
webrick (1.8.1)
|
|
123
|
-
yard (0.9.34)
|
|
124
|
-
zeitwerk (2.6.12)
|
|
125
|
-
|
|
126
|
-
PLATFORMS
|
|
127
|
-
ruby
|
|
128
|
-
|
|
129
|
-
DEPENDENCIES
|
|
130
|
-
ammeter (~> 1.1.3)
|
|
131
|
-
formtastic!
|
|
132
|
-
rake
|
|
133
|
-
rspec-dom-testing (>= 0.1.0)
|
|
134
|
-
rspec-mocks (~> 3.12.2)
|
|
135
|
-
rspec-rails (>= 4.0)
|
|
136
|
-
sqlite3 (~> 1.4)
|
|
137
|
-
yard (~> 0.9.20)
|
|
138
|
-
|
|
139
|
-
BUNDLED WITH
|
|
140
|
-
2.3.18
|
|
@@ -1,33 +0,0 @@
|
|
|
1
|
-
/* additional stylesheets only for IE6, if you wish to support it */
|
|
2
|
-
|
|
3
|
-
/* legend labels apper to have a left margin or padding I couldn't get rid of cleanly in main stylesheet */
|
|
4
|
-
.formtastic .input fieldset legend.label {
|
|
5
|
-
margin-left:-7px;
|
|
6
|
-
}
|
|
7
|
-
|
|
8
|
-
/* checkbox and radio inputs appear to have a margin around them that I couldn't remove in main stylesheet */
|
|
9
|
-
.formtastic .choice label input,
|
|
10
|
-
.formtastic .boolean label input {
|
|
11
|
-
position:relative;
|
|
12
|
-
left:-1px;
|
|
13
|
-
size:15px;
|
|
14
|
-
margin-left:0;
|
|
15
|
-
margin-right:0;
|
|
16
|
-
}
|
|
17
|
-
|
|
18
|
-
/* inline hints and errors appear a few pixel too far over to the left */
|
|
19
|
-
.formtastic .inline-hints,
|
|
20
|
-
.formtastic .inline-errors {
|
|
21
|
-
padding-left:3px;
|
|
22
|
-
}
|
|
23
|
-
|
|
24
|
-
/* fragment (eg year, month, day) appear a few pixels too far to the left*/
|
|
25
|
-
.formtastic .fragment {
|
|
26
|
-
padding-left:3px;
|
|
27
|
-
}
|
|
28
|
-
|
|
29
|
-
.formtastic .buttons,
|
|
30
|
-
.formtastic .inputs,
|
|
31
|
-
.formtastic .input {
|
|
32
|
-
zoom:1;
|
|
33
|
-
}
|
|
@@ -1,23 +0,0 @@
|
|
|
1
|
-
/* additional stylesheets only for IE7, if you wish to support it */
|
|
2
|
-
|
|
3
|
-
/* legend labels apper to have a left margin or padding I couldn't get rid of cleanly in main stylesheet */
|
|
4
|
-
.formtastic .input fieldset legend.label {
|
|
5
|
-
margin-left:-7px;
|
|
6
|
-
}
|
|
7
|
-
|
|
8
|
-
/* checkbox and radio inputs appear to have a margin around them that I couldn't remove in main stylesheet */
|
|
9
|
-
.formtastic .choice label input,
|
|
10
|
-
.formtastic .boolean label input {
|
|
11
|
-
position:relative;
|
|
12
|
-
left:-4px;
|
|
13
|
-
right:-4px;
|
|
14
|
-
size:15px;
|
|
15
|
-
margin-left:0;
|
|
16
|
-
margin-right:0;
|
|
17
|
-
}
|
|
18
|
-
|
|
19
|
-
.formtastic .buttons,
|
|
20
|
-
.formtastic .inputs,
|
|
21
|
-
.formtastic .input {
|
|
22
|
-
zoom:1;
|
|
23
|
-
}
|
data/gemfiles/rails_6.0/Gemfile
DELETED
data/gemfiles/rails_6.1/Gemfile
DELETED
data/gemfiles/rails_7.0/Gemfile
DELETED
data/gemfiles/rails_7.1/Gemfile
DELETED
data/gemfiles/rails_edge/Gemfile
DELETED
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
source "https://rubygems.org"
|
|
2
|
-
|
|
3
|
-
gem "rails", git: "https://github.com/rails/rails.git", branch: "main"
|
|
4
|
-
gem "rack", git: "https://github.com/rack/rack.git"
|
|
5
|
-
gem "i18n", git: "https://github.com/svenfuchs/i18n.git"
|
|
6
|
-
gem "arel", git: "https://github.com/rails/arel.git"
|
|
7
|
-
gem "rspec-rails", git: "https://github.com/rspec/rspec-rails.git"
|
|
8
|
-
gem "rspec-mocks", git: "https://github.com/rspec/rspec-mocks.git"
|
|
9
|
-
gem "rspec-support", git: "https://github.com/rspec/rspec-support.git"
|
|
10
|
-
gem "rspec-core", git: "https://github.com/rspec/rspec-core.git"
|
|
11
|
-
gem "rspec-expectations", git: "https://github.com/rspec/rspec-expectations.git"
|
|
12
|
-
|
|
13
|
-
gemspec path: "../.."
|
data/lib/formtastic/engine.rb
DELETED
|
@@ -1,14 +0,0 @@
|
|
|
1
|
-
# frozen_string_literal: true
|
|
2
|
-
module Formtastic
|
|
3
|
-
# Required for formtastic.css to be discoverable in the asset pipeline
|
|
4
|
-
# @private
|
|
5
|
-
class Engine < ::Rails::Engine
|
|
6
|
-
initializer 'formtastic.initialize' do
|
|
7
|
-
ActiveSupport.on_load(:action_view) do
|
|
8
|
-
include Formtastic::Helpers::FormHelper
|
|
9
|
-
end
|
|
10
|
-
end
|
|
11
|
-
|
|
12
|
-
config.eager_load_namespaces << Formtastic
|
|
13
|
-
end
|
|
14
|
-
end
|