actionpack 3.2.22.5 → 4.0.0.beta1
Sign up to get free protection for your applications and to get access to all the features.
Potentially problematic release.
This version of actionpack might be problematic. Click here for more details.
- checksums.yaml +4 -4
- data/CHANGELOG.md +641 -418
- data/MIT-LICENSE +1 -1
- data/README.rdoc +5 -288
- data/lib/abstract_controller.rb +1 -8
- data/lib/abstract_controller/asset_paths.rb +2 -2
- data/lib/abstract_controller/base.rb +39 -37
- data/lib/abstract_controller/callbacks.rb +101 -82
- data/lib/abstract_controller/collector.rb +7 -3
- data/lib/abstract_controller/helpers.rb +23 -11
- data/lib/abstract_controller/layouts.rb +68 -73
- data/lib/abstract_controller/logger.rb +1 -2
- data/lib/abstract_controller/rendering.rb +22 -13
- data/lib/abstract_controller/translation.rb +16 -1
- data/lib/abstract_controller/url_for.rb +6 -6
- data/lib/abstract_controller/view_paths.rb +1 -1
- data/lib/action_controller.rb +15 -6
- data/lib/action_controller/base.rb +46 -22
- data/lib/action_controller/caching.rb +46 -33
- data/lib/action_controller/caching/fragments.rb +23 -53
- data/lib/action_controller/deprecated.rb +5 -1
- data/lib/action_controller/deprecated/integration_test.rb +3 -0
- data/lib/action_controller/log_subscriber.rb +11 -8
- data/lib/action_controller/metal.rb +16 -30
- data/lib/action_controller/metal/conditional_get.rb +76 -32
- data/lib/action_controller/metal/data_streaming.rb +20 -26
- data/lib/action_controller/metal/exceptions.rb +19 -6
- data/lib/action_controller/metal/flash.rb +24 -9
- data/lib/action_controller/metal/force_ssl.rb +32 -9
- data/lib/action_controller/metal/head.rb +25 -4
- data/lib/action_controller/metal/helpers.rb +6 -9
- data/lib/action_controller/metal/hide_actions.rb +1 -2
- data/lib/action_controller/metal/http_authentication.rb +105 -87
- data/lib/action_controller/metal/implicit_render.rb +1 -1
- data/lib/action_controller/metal/instrumentation.rb +2 -1
- data/lib/action_controller/metal/live.rb +141 -0
- data/lib/action_controller/metal/mime_responds.rb +161 -47
- data/lib/action_controller/metal/params_wrapper.rb +112 -74
- data/lib/action_controller/metal/rack_delegation.rb +9 -3
- data/lib/action_controller/metal/redirecting.rb +15 -20
- data/lib/action_controller/metal/renderers.rb +11 -9
- data/lib/action_controller/metal/rendering.rb +8 -0
- data/lib/action_controller/metal/request_forgery_protection.rb +112 -19
- data/lib/action_controller/metal/responder.rb +20 -19
- data/lib/action_controller/metal/streaming.rb +12 -18
- data/lib/action_controller/metal/strong_parameters.rb +516 -0
- data/lib/action_controller/metal/testing.rb +13 -18
- data/lib/action_controller/metal/url_for.rb +27 -25
- data/lib/action_controller/model_naming.rb +12 -0
- data/lib/action_controller/railtie.rb +33 -17
- data/lib/action_controller/railties/helpers.rb +22 -0
- data/lib/action_controller/record_identifier.rb +18 -72
- data/lib/action_controller/test_case.rb +215 -123
- data/lib/action_controller/vendor/html-scanner.rb +4 -19
- data/lib/action_dispatch.rb +27 -19
- data/lib/action_dispatch/http/cache.rb +63 -11
- data/lib/action_dispatch/http/filter_parameters.rb +18 -8
- data/lib/action_dispatch/http/filter_redirect.rb +37 -0
- data/lib/action_dispatch/http/headers.rb +27 -19
- data/lib/action_dispatch/http/mime_negotiation.rb +25 -2
- data/lib/action_dispatch/http/mime_type.rb +145 -113
- data/lib/action_dispatch/http/mime_types.rb +1 -1
- data/lib/action_dispatch/http/parameter_filter.rb +44 -46
- data/lib/action_dispatch/http/parameters.rb +12 -5
- data/lib/action_dispatch/http/rack_cache.rb +2 -3
- data/lib/action_dispatch/http/request.rb +49 -18
- data/lib/action_dispatch/http/response.rb +129 -35
- data/lib/action_dispatch/http/upload.rb +60 -17
- data/lib/action_dispatch/http/url.rb +53 -31
- data/lib/action_dispatch/journey.rb +5 -0
- data/lib/action_dispatch/journey/backwards.rb +5 -0
- data/lib/action_dispatch/journey/formatter.rb +146 -0
- data/lib/action_dispatch/journey/gtg/builder.rb +162 -0
- data/lib/action_dispatch/journey/gtg/simulator.rb +44 -0
- data/lib/action_dispatch/journey/gtg/transition_table.rb +156 -0
- data/lib/action_dispatch/journey/nfa/builder.rb +76 -0
- data/lib/action_dispatch/journey/nfa/dot.rb +36 -0
- data/lib/action_dispatch/journey/nfa/simulator.rb +47 -0
- data/lib/action_dispatch/journey/nfa/transition_table.rb +163 -0
- data/lib/action_dispatch/journey/nodes/node.rb +124 -0
- data/lib/action_dispatch/journey/parser.rb +206 -0
- data/lib/action_dispatch/journey/parser.y +47 -0
- data/lib/action_dispatch/journey/parser_extras.rb +23 -0
- data/lib/action_dispatch/journey/path/pattern.rb +196 -0
- data/lib/action_dispatch/journey/route.rb +116 -0
- data/lib/action_dispatch/journey/router.rb +164 -0
- data/lib/action_dispatch/journey/router/strexp.rb +24 -0
- data/lib/action_dispatch/journey/router/utils.rb +54 -0
- data/lib/action_dispatch/journey/routes.rb +75 -0
- data/lib/action_dispatch/journey/scanner.rb +61 -0
- data/lib/action_dispatch/journey/visitors.rb +189 -0
- data/lib/action_dispatch/journey/visualizer/fsm.css +34 -0
- data/lib/action_dispatch/journey/visualizer/fsm.js +134 -0
- data/lib/action_dispatch/journey/visualizer/index.html.erb +52 -0
- data/lib/action_dispatch/middleware/callbacks.rb +9 -4
- data/lib/action_dispatch/middleware/cookies.rb +168 -57
- data/lib/action_dispatch/middleware/debug_exceptions.rb +26 -17
- data/lib/action_dispatch/middleware/exception_wrapper.rb +27 -3
- data/lib/action_dispatch/middleware/flash.rb +58 -58
- data/lib/action_dispatch/middleware/params_parser.rb +14 -29
- data/lib/action_dispatch/middleware/public_exceptions.rb +31 -14
- data/lib/action_dispatch/middleware/reloader.rb +6 -6
- data/lib/action_dispatch/middleware/remote_ip.rb +145 -39
- data/lib/action_dispatch/middleware/request_id.rb +2 -6
- data/lib/action_dispatch/middleware/session/abstract_store.rb +22 -20
- data/lib/action_dispatch/middleware/session/cache_store.rb +3 -3
- data/lib/action_dispatch/middleware/session/cookie_store.rb +81 -7
- data/lib/action_dispatch/middleware/session/mem_cache_store.rb +8 -3
- data/lib/action_dispatch/middleware/show_exceptions.rb +12 -45
- data/lib/action_dispatch/middleware/ssl.rb +70 -0
- data/lib/action_dispatch/middleware/stack.rb +6 -1
- data/lib/action_dispatch/middleware/static.rb +5 -24
- data/lib/action_dispatch/middleware/templates/rescues/_request_and_response.erb +14 -11
- data/lib/action_dispatch/middleware/templates/rescues/_source.erb +25 -0
- data/lib/action_dispatch/middleware/templates/rescues/_trace.erb +3 -3
- data/lib/action_dispatch/middleware/templates/rescues/diagnostics.erb +15 -9
- data/lib/action_dispatch/middleware/templates/rescues/layout.erb +121 -5
- data/lib/action_dispatch/middleware/templates/rescues/missing_template.erb +7 -2
- data/lib/action_dispatch/middleware/templates/rescues/routing_error.erb +30 -15
- data/lib/action_dispatch/middleware/templates/rescues/template_error.erb +39 -13
- data/lib/action_dispatch/middleware/templates/rescues/unknown_action.erb +6 -2
- data/lib/action_dispatch/middleware/templates/routes/_route.html.erb +16 -0
- data/lib/action_dispatch/middleware/templates/routes/_table.html.erb +144 -0
- data/lib/action_dispatch/railtie.rb +16 -6
- data/lib/action_dispatch/request/session.rb +181 -0
- data/lib/action_dispatch/routing.rb +41 -40
- data/lib/action_dispatch/routing/inspector.rb +240 -0
- data/lib/action_dispatch/routing/mapper.rb +501 -273
- data/lib/action_dispatch/routing/polymorphic_routes.rb +16 -20
- data/lib/action_dispatch/routing/redirection.rb +46 -29
- data/lib/action_dispatch/routing/route_set.rb +203 -164
- data/lib/action_dispatch/routing/routes_proxy.rb +2 -0
- data/lib/action_dispatch/routing/url_for.rb +48 -33
- data/lib/action_dispatch/testing/assertions/dom.rb +3 -13
- data/lib/action_dispatch/testing/assertions/response.rb +32 -40
- data/lib/action_dispatch/testing/assertions/routing.rb +40 -39
- data/lib/action_dispatch/testing/assertions/selector.rb +15 -20
- data/lib/action_dispatch/testing/assertions/tag.rb +20 -23
- data/lib/action_dispatch/testing/integration.rb +41 -22
- data/lib/action_dispatch/testing/test_process.rb +9 -6
- data/lib/action_dispatch/testing/test_request.rb +7 -3
- data/lib/action_pack.rb +1 -1
- data/lib/action_pack/version.rb +4 -4
- data/lib/action_view.rb +17 -8
- data/lib/action_view/base.rb +15 -34
- data/lib/action_view/buffers.rb +1 -1
- data/lib/action_view/context.rb +4 -4
- data/lib/action_view/dependency_tracker.rb +91 -0
- data/lib/action_view/digestor.rb +85 -0
- data/lib/action_view/flows.rb +1 -4
- data/lib/action_view/helpers.rb +2 -4
- data/lib/action_view/helpers/active_model_helper.rb +3 -4
- data/lib/action_view/helpers/asset_tag_helper.rb +211 -353
- data/lib/action_view/helpers/asset_url_helper.rb +354 -0
- data/lib/action_view/helpers/atom_feed_helper.rb +13 -10
- data/lib/action_view/helpers/cache_helper.rb +150 -18
- data/lib/action_view/helpers/capture_helper.rb +42 -29
- data/lib/action_view/helpers/csrf_helper.rb +0 -2
- data/lib/action_view/helpers/date_helper.rb +268 -247
- data/lib/action_view/helpers/debug_helper.rb +10 -11
- data/lib/action_view/helpers/form_helper.rb +904 -547
- data/lib/action_view/helpers/form_options_helper.rb +341 -166
- data/lib/action_view/helpers/form_tag_helper.rb +188 -88
- data/lib/action_view/helpers/javascript_helper.rb +23 -16
- data/lib/action_view/helpers/number_helper.rb +148 -354
- data/lib/action_view/helpers/output_safety_helper.rb +3 -3
- data/lib/action_view/helpers/record_tag_helper.rb +17 -22
- data/lib/action_view/helpers/rendering_helper.rb +2 -4
- data/lib/action_view/helpers/sanitize_helper.rb +3 -6
- data/lib/action_view/helpers/tag_helper.rb +43 -37
- data/lib/action_view/helpers/tags.rb +39 -0
- data/lib/action_view/helpers/tags/base.rb +148 -0
- data/lib/action_view/helpers/tags/check_box.rb +64 -0
- data/lib/action_view/helpers/tags/checkable.rb +16 -0
- data/lib/action_view/helpers/tags/collection_check_boxes.rb +43 -0
- data/lib/action_view/helpers/tags/collection_helpers.rb +83 -0
- data/lib/action_view/helpers/tags/collection_radio_buttons.rb +36 -0
- data/lib/action_view/helpers/tags/collection_select.rb +28 -0
- data/lib/action_view/helpers/tags/color_field.rb +25 -0
- data/lib/action_view/helpers/tags/date_field.rb +13 -0
- data/lib/action_view/helpers/tags/date_select.rb +72 -0
- data/lib/action_view/helpers/tags/datetime_field.rb +22 -0
- data/lib/action_view/helpers/tags/datetime_local_field.rb +19 -0
- data/lib/action_view/helpers/tags/datetime_select.rb +8 -0
- data/lib/action_view/helpers/tags/email_field.rb +8 -0
- data/lib/action_view/helpers/tags/file_field.rb +8 -0
- data/lib/action_view/helpers/tags/grouped_collection_select.rb +29 -0
- data/lib/action_view/helpers/tags/hidden_field.rb +8 -0
- data/lib/action_view/helpers/tags/label.rb +65 -0
- data/lib/action_view/helpers/tags/month_field.rb +13 -0
- data/lib/action_view/helpers/tags/number_field.rb +18 -0
- data/lib/action_view/helpers/tags/password_field.rb +12 -0
- data/lib/action_view/helpers/tags/radio_button.rb +31 -0
- data/lib/action_view/helpers/tags/range_field.rb +8 -0
- data/lib/action_view/helpers/tags/search_field.rb +24 -0
- data/lib/action_view/helpers/tags/select.rb +41 -0
- data/lib/action_view/helpers/tags/tel_field.rb +8 -0
- data/lib/action_view/helpers/tags/text_area.rb +18 -0
- data/lib/action_view/helpers/tags/text_field.rb +29 -0
- data/lib/action_view/helpers/tags/time_field.rb +13 -0
- data/lib/action_view/helpers/tags/time_select.rb +8 -0
- data/lib/action_view/helpers/tags/time_zone_select.rb +20 -0
- data/lib/action_view/helpers/tags/url_field.rb +8 -0
- data/lib/action_view/helpers/tags/week_field.rb +13 -0
- data/lib/action_view/helpers/text_helper.rb +126 -113
- data/lib/action_view/helpers/translation_helper.rb +32 -16
- data/lib/action_view/helpers/url_helper.rb +200 -271
- data/lib/action_view/locale/en.yml +1 -105
- data/lib/action_view/log_subscriber.rb +6 -4
- data/lib/action_view/lookup_context.rb +15 -39
- data/lib/action_view/model_naming.rb +12 -0
- data/lib/action_view/path_set.rb +9 -39
- data/lib/action_view/railtie.rb +6 -22
- data/lib/action_view/record_identifier.rb +84 -0
- data/lib/action_view/renderer/abstract_renderer.rb +10 -19
- data/lib/action_view/renderer/partial_renderer.rb +144 -81
- data/lib/action_view/renderer/renderer.rb +2 -19
- data/lib/action_view/renderer/streaming_template_renderer.rb +2 -5
- data/lib/action_view/renderer/template_renderer.rb +14 -13
- data/lib/action_view/routing_url_for.rb +107 -0
- data/lib/action_view/template.rb +22 -21
- data/lib/action_view/template/error.rb +22 -12
- data/lib/action_view/template/handlers.rb +12 -9
- data/lib/action_view/template/handlers/builder.rb +1 -1
- data/lib/action_view/template/handlers/erb.rb +11 -16
- data/lib/action_view/template/handlers/raw.rb +11 -0
- data/lib/action_view/template/resolver.rb +111 -83
- data/lib/action_view/template/text.rb +12 -8
- data/lib/action_view/template/types.rb +57 -0
- data/lib/action_view/test_case.rb +66 -43
- data/lib/action_view/testing/resolvers.rb +3 -2
- data/lib/action_view/vendor/html-scanner.rb +20 -0
- data/lib/{action_controller → action_view}/vendor/html-scanner/html/document.rb +0 -0
- data/lib/{action_controller → action_view}/vendor/html-scanner/html/node.rb +12 -12
- data/lib/{action_controller → action_view}/vendor/html-scanner/html/sanitizer.rb +18 -7
- data/lib/{action_controller → action_view}/vendor/html-scanner/html/selector.rb +1 -1
- data/lib/{action_controller → action_view}/vendor/html-scanner/html/tokenizer.rb +1 -1
- data/lib/{action_controller → action_view}/vendor/html-scanner/html/version.rb +0 -0
- metadata +135 -125
- data/lib/action_controller/caching/actions.rb +0 -185
- data/lib/action_controller/caching/pages.rb +0 -187
- data/lib/action_controller/caching/sweeping.rb +0 -97
- data/lib/action_controller/deprecated/performance_test.rb +0 -1
- data/lib/action_controller/metal/compatibility.rb +0 -65
- data/lib/action_controller/metal/session_management.rb +0 -14
- data/lib/action_controller/railties/paths.rb +0 -25
- data/lib/action_dispatch/middleware/best_standards_support.rb +0 -30
- data/lib/action_dispatch/middleware/body_proxy.rb +0 -30
- data/lib/action_dispatch/middleware/head.rb +0 -18
- data/lib/action_dispatch/middleware/rescue.rb +0 -26
- data/lib/action_dispatch/testing/performance_test.rb +0 -10
- data/lib/action_view/asset_paths.rb +0 -142
- data/lib/action_view/helpers/asset_paths.rb +0 -7
- data/lib/action_view/helpers/asset_tag_helpers/asset_include_tag.rb +0 -146
- data/lib/action_view/helpers/asset_tag_helpers/asset_paths.rb +0 -93
- data/lib/action_view/helpers/asset_tag_helpers/javascript_tag_helpers.rb +0 -193
- data/lib/action_view/helpers/asset_tag_helpers/stylesheet_tag_helpers.rb +0 -148
- data/lib/sprockets/assets.rake +0 -99
- data/lib/sprockets/bootstrap.rb +0 -37
- data/lib/sprockets/compressors.rb +0 -83
- data/lib/sprockets/helpers.rb +0 -6
- data/lib/sprockets/helpers/isolated_helper.rb +0 -13
- data/lib/sprockets/helpers/rails_helper.rb +0 -182
- data/lib/sprockets/railtie.rb +0 -62
- data/lib/sprockets/static_compiler.rb +0 -56
@@ -1,5 +1,3 @@
|
|
1
|
-
require 'active_support/core_ext/object/blank'
|
2
|
-
require 'active_support/core_ext/module/delegation'
|
3
1
|
require 'active_support/core_ext/module/remove_method'
|
4
2
|
require 'action_controller'
|
5
3
|
require 'action_controller/test_case'
|
@@ -40,10 +38,13 @@ module ActionView
|
|
40
38
|
include ActionView::Context
|
41
39
|
|
42
40
|
include ActionDispatch::Routing::PolymorphicRoutes
|
43
|
-
include ActionController::RecordIdentifier
|
44
41
|
|
45
42
|
include AbstractController::Helpers
|
46
43
|
include ActionView::Helpers
|
44
|
+
include ActionView::RecordIdentifier
|
45
|
+
include ActionView::RoutingUrlFor
|
46
|
+
|
47
|
+
include ActiveSupport::Testing::ConstantLookup
|
47
48
|
|
48
49
|
delegate :lookup_context, :to => :controller
|
49
50
|
attr_accessor :controller, :output_buffer, :rendered
|
@@ -59,10 +60,9 @@ module ActionView
|
|
59
60
|
end
|
60
61
|
|
61
62
|
def determine_default_helper_class(name)
|
62
|
-
|
63
|
-
|
64
|
-
|
65
|
-
nil
|
63
|
+
determine_constant_from_test_name(name) do |constant|
|
64
|
+
Module === constant && !(Class === constant)
|
65
|
+
end
|
66
66
|
end
|
67
67
|
|
68
68
|
def helper_method(*methods)
|
@@ -116,8 +116,33 @@ module ActionView
|
|
116
116
|
output
|
117
117
|
end
|
118
118
|
|
119
|
-
def
|
120
|
-
@
|
119
|
+
def rendered_views
|
120
|
+
@_rendered_views ||= RenderedViewsCollection.new
|
121
|
+
end
|
122
|
+
|
123
|
+
class RenderedViewsCollection
|
124
|
+
def initialize
|
125
|
+
@rendered_views ||= Hash.new { |hash, key| hash[key] = [] }
|
126
|
+
end
|
127
|
+
|
128
|
+
def add(view, locals)
|
129
|
+
@rendered_views[view] ||= []
|
130
|
+
@rendered_views[view] << locals
|
131
|
+
end
|
132
|
+
|
133
|
+
def locals_for(view)
|
134
|
+
@rendered_views[view]
|
135
|
+
end
|
136
|
+
|
137
|
+
def rendered_views
|
138
|
+
@rendered_views.keys
|
139
|
+
end
|
140
|
+
|
141
|
+
def view_rendered?(view, expected_locals)
|
142
|
+
locals_for(view).any? do |actual_locals|
|
143
|
+
expected_locals.all? {|key, value| value == actual_locals[key] }
|
144
|
+
end
|
145
|
+
end
|
121
146
|
end
|
122
147
|
|
123
148
|
included do
|
@@ -153,18 +178,18 @@ module ActionView
|
|
153
178
|
end
|
154
179
|
|
155
180
|
module Locals
|
156
|
-
attr_accessor :
|
181
|
+
attr_accessor :rendered_views
|
157
182
|
|
158
183
|
def render(options = {}, local_assigns = {})
|
159
184
|
case options
|
160
185
|
when Hash
|
161
186
|
if block_given?
|
162
|
-
|
187
|
+
rendered_views.add options[:layout], options[:locals]
|
163
188
|
elsif options.key?(:partial)
|
164
|
-
|
189
|
+
rendered_views.add options[:partial], options[:locals]
|
165
190
|
end
|
166
191
|
else
|
167
|
-
|
192
|
+
rendered_views.add options, local_assigns
|
168
193
|
end
|
169
194
|
|
170
195
|
super
|
@@ -177,7 +202,7 @@ module ActionView
|
|
177
202
|
view = @controller.view_context
|
178
203
|
view.singleton_class.send :include, _helpers
|
179
204
|
view.extend(Locals)
|
180
|
-
view.
|
205
|
+
view.rendered_views = self.rendered_views
|
181
206
|
view.output_buffer = self.output_buffer
|
182
207
|
view
|
183
208
|
end
|
@@ -185,33 +210,33 @@ module ActionView
|
|
185
210
|
|
186
211
|
alias_method :_view, :view
|
187
212
|
|
188
|
-
INTERNAL_IVARS =
|
189
|
-
|
190
|
-
|
191
|
-
|
192
|
-
|
193
|
-
|
194
|
-
|
195
|
-
|
196
|
-
|
197
|
-
|
198
|
-
|
199
|
-
|
200
|
-
|
201
|
-
|
202
|
-
|
203
|
-
|
204
|
-
|
205
|
-
|
206
|
-
|
207
|
-
|
208
|
-
|
209
|
-
|
210
|
-
|
211
|
-
|
213
|
+
INTERNAL_IVARS = [
|
214
|
+
:@__name__,
|
215
|
+
:@__io__,
|
216
|
+
:@_assertion_wrapped,
|
217
|
+
:@_assertions,
|
218
|
+
:@_result,
|
219
|
+
:@_routes,
|
220
|
+
:@controller,
|
221
|
+
:@_layouts,
|
222
|
+
:@_rendered_views,
|
223
|
+
:@method_name,
|
224
|
+
:@output_buffer,
|
225
|
+
:@_partials,
|
226
|
+
:@passed,
|
227
|
+
:@rendered,
|
228
|
+
:@request,
|
229
|
+
:@routes,
|
230
|
+
:@tagged_logger,
|
231
|
+
:@_templates,
|
232
|
+
:@options,
|
233
|
+
:@test_passed,
|
234
|
+
:@view,
|
235
|
+
:@view_context_class
|
236
|
+
]
|
212
237
|
|
213
238
|
def _user_defined_ivars
|
214
|
-
instance_variables
|
239
|
+
instance_variables - INTERNAL_IVARS
|
215
240
|
end
|
216
241
|
|
217
242
|
# Returns a Hash of instance variables and their values, as defined by
|
@@ -219,8 +244,8 @@ module ActionView
|
|
219
244
|
# rendered. This is generally intended for internal use and extension
|
220
245
|
# frameworks.
|
221
246
|
def view_assigns
|
222
|
-
Hash[_user_defined_ivars.map do |
|
223
|
-
[
|
247
|
+
Hash[_user_defined_ivars.map do |ivar|
|
248
|
+
[ivar[1..-1].to_sym, instance_variable_get(ivar)]
|
224
249
|
end]
|
225
250
|
end
|
226
251
|
|
@@ -237,10 +262,8 @@ module ActionView
|
|
237
262
|
super
|
238
263
|
end
|
239
264
|
end
|
240
|
-
|
241
265
|
end
|
242
266
|
|
243
267
|
include Behavior
|
244
|
-
|
245
268
|
end
|
246
269
|
end
|
@@ -19,7 +19,7 @@ module ActionView #:nodoc:
|
|
19
19
|
|
20
20
|
private
|
21
21
|
|
22
|
-
def query(path, exts, formats
|
22
|
+
def query(path, exts, formats)
|
23
23
|
query = ""
|
24
24
|
EXTENSIONS.each do |ext|
|
25
25
|
query << '(' << exts[ext].map {|e| e && Regexp.escape(".#{e}") }.join('|') << '|)'
|
@@ -40,10 +40,11 @@ module ActionView #:nodoc:
|
|
40
40
|
end
|
41
41
|
|
42
42
|
class NullResolver < PathResolver
|
43
|
-
def query(path, exts, formats
|
43
|
+
def query(path, exts, formats)
|
44
44
|
handler, format = extract_handler_and_format(path, formats)
|
45
45
|
[ActionView::Template.new("Template generated by Null Resolver", path, handler, :virtual_path => path, :format => format)]
|
46
46
|
end
|
47
47
|
end
|
48
48
|
|
49
49
|
end
|
50
|
+
|
@@ -0,0 +1,20 @@
|
|
1
|
+
$LOAD_PATH.unshift "#{File.dirname(__FILE__)}/html-scanner"
|
2
|
+
|
3
|
+
module HTML
|
4
|
+
extend ActiveSupport::Autoload
|
5
|
+
|
6
|
+
eager_autoload do
|
7
|
+
autoload :CDATA, 'html/node'
|
8
|
+
autoload :Document, 'html/document'
|
9
|
+
autoload :FullSanitizer, 'html/sanitizer'
|
10
|
+
autoload :LinkSanitizer, 'html/sanitizer'
|
11
|
+
autoload :Node, 'html/node'
|
12
|
+
autoload :Sanitizer, 'html/sanitizer'
|
13
|
+
autoload :Selector, 'html/selector'
|
14
|
+
autoload :Tag, 'html/node'
|
15
|
+
autoload :Text, 'html/node'
|
16
|
+
autoload :Tokenizer, 'html/tokenizer'
|
17
|
+
autoload :Version, 'html/version'
|
18
|
+
autoload :WhiteListSanitizer, 'html/sanitizer'
|
19
|
+
end
|
20
|
+
end
|
File without changes
|
@@ -383,32 +383,32 @@ module HTML #:nodoc:
|
|
383
383
|
# Usage:
|
384
384
|
#
|
385
385
|
# # test if the node is a "span" tag
|
386
|
-
# node.match :
|
386
|
+
# node.match tag: "span"
|
387
387
|
#
|
388
388
|
# # test if the node's parent is a "div"
|
389
|
-
# node.match :
|
389
|
+
# node.match parent: { tag: "div" }
|
390
390
|
#
|
391
391
|
# # test if any of the node's ancestors are "table" tags
|
392
|
-
# node.match :
|
392
|
+
# node.match ancestor: { tag: "table" }
|
393
393
|
#
|
394
394
|
# # test if any of the node's immediate children are "em" tags
|
395
|
-
# node.match :
|
395
|
+
# node.match child: { tag: "em" }
|
396
396
|
#
|
397
397
|
# # test if any of the node's descendants are "strong" tags
|
398
|
-
# node.match :
|
398
|
+
# node.match descendant: { tag: "strong" }
|
399
399
|
#
|
400
400
|
# # test if the node has between 2 and 4 span tags as immediate children
|
401
|
-
# node.match :
|
401
|
+
# node.match children: { count: 2..4, only: { tag: "span" } }
|
402
402
|
#
|
403
403
|
# # get funky: test to see if the node is a "div", has a "ul" ancestor
|
404
404
|
# # and an "li" parent (with "class" = "enum"), and whether or not it has
|
405
405
|
# # a "span" descendant that contains # text matching /hello world/:
|
406
|
-
# node.match :
|
407
|
-
# :
|
408
|
-
# :
|
409
|
-
# :
|
410
|
-
# :
|
411
|
-
# :
|
406
|
+
# node.match tag: "div",
|
407
|
+
# ancestor: { tag: "ul" },
|
408
|
+
# parent: { tag: "li",
|
409
|
+
# attributes: { class: "enum" } },
|
410
|
+
# descendant: { tag: "span",
|
411
|
+
# child: /hello world/ }
|
412
412
|
def match(conditions)
|
413
413
|
conditions = validate_conditions(conditions)
|
414
414
|
# check content of child nodes
|
@@ -1,10 +1,11 @@
|
|
1
1
|
require 'set'
|
2
2
|
require 'cgi'
|
3
|
-
require 'active_support/core_ext/class/
|
3
|
+
require 'active_support/core_ext/class/attribute_accessors'
|
4
4
|
|
5
5
|
module HTML
|
6
6
|
class Sanitizer
|
7
7
|
def sanitize(text, options = {})
|
8
|
+
validate_options(options)
|
8
9
|
return text unless sanitizeable?(text)
|
9
10
|
tokenize(text, options).join
|
10
11
|
end
|
@@ -27,6 +28,16 @@ module HTML
|
|
27
28
|
def process_node(node, result, options)
|
28
29
|
result << node.to_s
|
29
30
|
end
|
31
|
+
|
32
|
+
def validate_options(options)
|
33
|
+
if options[:tags] && !options[:tags].is_a?(Enumerable)
|
34
|
+
raise ArgumentError, "You should pass :tags as an Enumerable"
|
35
|
+
end
|
36
|
+
|
37
|
+
if options[:attributes] && !options[:attributes].is_a?(Enumerable)
|
38
|
+
raise ArgumentError, "You should pass :attributes as an Enumerable"
|
39
|
+
end
|
40
|
+
end
|
30
41
|
end
|
31
42
|
|
32
43
|
class FullSanitizer < Sanitizer
|
@@ -66,7 +77,7 @@ module HTML
|
|
66
77
|
|
67
78
|
# A regular expression of the valid characters used to separate protocols like
|
68
79
|
# the ':' in 'http://foo.com'
|
69
|
-
self.protocol_separator = /:|(�*58)|(p)|(
|
80
|
+
self.protocol_separator = /:|(�*58)|(p)|(%|%)3A/
|
70
81
|
|
71
82
|
# Specifies a Set of HTML attributes that can have URIs.
|
72
83
|
self.uri_attributes = Set.new(%w(href src cite action longdesc xlink:href lowsrc))
|
@@ -88,7 +99,7 @@ module HTML
|
|
88
99
|
self.allowed_protocols = Set.new(%w(ed2k ftp http https irc mailto news gopher nntp telnet webcal xmpp callto
|
89
100
|
feed svn urn aim rsync tag ssh sftp rtsp afs))
|
90
101
|
|
91
|
-
# Specifies the default Set of acceptable css
|
102
|
+
# Specifies the default Set of acceptable css properties that #sanitize and #sanitize_css will accept.
|
92
103
|
self.allowed_css_properties = Set.new(%w(azimuth background-color border-bottom-color border-collapse
|
93
104
|
border-color border-left-color border-right-color border-top-color clear color cursor direction display
|
94
105
|
elevation float font font-family font-size font-style font-variant font-weight height letter-spacing line-height
|
@@ -110,8 +121,8 @@ module HTML
|
|
110
121
|
style = style.to_s.gsub(/url\s*\(\s*[^\s)]+?\s*\)\s*/, ' ')
|
111
122
|
|
112
123
|
# gauntlet
|
113
|
-
if style !~
|
114
|
-
style !~
|
124
|
+
if style !~ /^([:,;#%.\sa-zA-Z0-9!]|\w-\w|\'[\s\w]+\'|\"[\s\w]+\"|\([\d,\s]+\))*$/ ||
|
125
|
+
style !~ /^(\s*[-\w]+\s*:\s*[^:;]*(;|$)\s*)*$/
|
115
126
|
return ''
|
116
127
|
end
|
117
128
|
|
@@ -122,7 +133,7 @@ module HTML
|
|
122
133
|
elsif shorthand_css_properties.include?(prop.split('-')[0].downcase)
|
123
134
|
unless val.split().any? do |keyword|
|
124
135
|
!allowed_css_keywords.include?(keyword) &&
|
125
|
-
keyword !~
|
136
|
+
keyword !~ /^(#[0-9a-f]+|rgb\(\d+%?,\d*%?,?\d*%?\)?|\d{0,2}\.?\d{0,2}(cm|em|ex|in|mm|pc|pt|px|%|,|\))?)$/
|
126
137
|
end
|
127
138
|
clean << prop + ': ' + val + ';'
|
128
139
|
end
|
@@ -171,7 +182,7 @@ module HTML
|
|
171
182
|
|
172
183
|
def contains_bad_protocols?(attr_name, value)
|
173
184
|
uri_attributes.include?(attr_name) &&
|
174
|
-
(value =~ /(^[^\/:]*):|(�*58)|(p)|(
|
185
|
+
(value =~ /(^[^\/:]*):|(�*58)|(p)|(%|%)3A/ && !allowed_protocols.include?(value.split(protocol_separator).first.downcase.strip))
|
175
186
|
end
|
176
187
|
end
|
177
188
|
end
|
@@ -160,7 +160,7 @@ module HTML
|
|
160
160
|
# * <tt>:not(selector)</tt> -- Match the element only if the element does not
|
161
161
|
# match the simple selector.
|
162
162
|
#
|
163
|
-
# As you can see, <tt>:nth-child
|
163
|
+
# As you can see, <tt>:nth-child</tt> pseudo class and its variant can get quite
|
164
164
|
# tricky and the CSS specification doesn't do a much better job explaining it.
|
165
165
|
# But after reading the examples and trying a few combinations, it's easy to
|
166
166
|
# figure out.
|
File without changes
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: actionpack
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version:
|
4
|
+
version: 4.0.0.beta1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- David Heinemeier Hansson
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2013-02-26 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: activesupport
|
@@ -16,140 +16,98 @@ dependencies:
|
|
16
16
|
requirements:
|
17
17
|
- - '='
|
18
18
|
- !ruby/object:Gem::Version
|
19
|
-
version:
|
19
|
+
version: 4.0.0.beta1
|
20
20
|
type: :runtime
|
21
21
|
prerelease: false
|
22
22
|
version_requirements: !ruby/object:Gem::Requirement
|
23
23
|
requirements:
|
24
24
|
- - '='
|
25
25
|
- !ruby/object:Gem::Version
|
26
|
-
version:
|
27
|
-
- !ruby/object:Gem::Dependency
|
28
|
-
name: activemodel
|
29
|
-
requirement: !ruby/object:Gem::Requirement
|
30
|
-
requirements:
|
31
|
-
- - '='
|
32
|
-
- !ruby/object:Gem::Version
|
33
|
-
version: 3.2.22.5
|
34
|
-
type: :runtime
|
35
|
-
prerelease: false
|
36
|
-
version_requirements: !ruby/object:Gem::Requirement
|
37
|
-
requirements:
|
38
|
-
- - '='
|
39
|
-
- !ruby/object:Gem::Version
|
40
|
-
version: 3.2.22.5
|
41
|
-
- !ruby/object:Gem::Dependency
|
42
|
-
name: rack-cache
|
43
|
-
requirement: !ruby/object:Gem::Requirement
|
44
|
-
requirements:
|
45
|
-
- - "~>"
|
46
|
-
- !ruby/object:Gem::Version
|
47
|
-
version: '1.2'
|
48
|
-
type: :runtime
|
49
|
-
prerelease: false
|
50
|
-
version_requirements: !ruby/object:Gem::Requirement
|
51
|
-
requirements:
|
52
|
-
- - "~>"
|
53
|
-
- !ruby/object:Gem::Version
|
54
|
-
version: '1.2'
|
26
|
+
version: 4.0.0.beta1
|
55
27
|
- !ruby/object:Gem::Dependency
|
56
28
|
name: builder
|
57
29
|
requirement: !ruby/object:Gem::Requirement
|
58
30
|
requirements:
|
59
|
-
- -
|
31
|
+
- - ~>
|
60
32
|
- !ruby/object:Gem::Version
|
61
|
-
version: 3.
|
33
|
+
version: 3.1.0
|
62
34
|
type: :runtime
|
63
35
|
prerelease: false
|
64
36
|
version_requirements: !ruby/object:Gem::Requirement
|
65
37
|
requirements:
|
66
|
-
- -
|
38
|
+
- - ~>
|
67
39
|
- !ruby/object:Gem::Version
|
68
|
-
version: 3.
|
40
|
+
version: 3.1.0
|
69
41
|
- !ruby/object:Gem::Dependency
|
70
42
|
name: rack
|
71
43
|
requirement: !ruby/object:Gem::Requirement
|
72
44
|
requirements:
|
73
|
-
- -
|
45
|
+
- - ~>
|
74
46
|
- !ruby/object:Gem::Version
|
75
|
-
version: 1.
|
47
|
+
version: 1.5.2
|
76
48
|
type: :runtime
|
77
49
|
prerelease: false
|
78
50
|
version_requirements: !ruby/object:Gem::Requirement
|
79
51
|
requirements:
|
80
|
-
- -
|
52
|
+
- - ~>
|
81
53
|
- !ruby/object:Gem::Version
|
82
|
-
version: 1.
|
54
|
+
version: 1.5.2
|
83
55
|
- !ruby/object:Gem::Dependency
|
84
56
|
name: rack-test
|
85
57
|
requirement: !ruby/object:Gem::Requirement
|
86
58
|
requirements:
|
87
|
-
- -
|
59
|
+
- - ~>
|
88
60
|
- !ruby/object:Gem::Version
|
89
|
-
version: 0.6.
|
61
|
+
version: 0.6.2
|
90
62
|
type: :runtime
|
91
63
|
prerelease: false
|
92
64
|
version_requirements: !ruby/object:Gem::Requirement
|
93
65
|
requirements:
|
94
|
-
- -
|
66
|
+
- - ~>
|
95
67
|
- !ruby/object:Gem::Version
|
96
|
-
version: 0.6.
|
68
|
+
version: 0.6.2
|
97
69
|
- !ruby/object:Gem::Dependency
|
98
|
-
name:
|
99
|
-
requirement: !ruby/object:Gem::Requirement
|
100
|
-
requirements:
|
101
|
-
- - "~>"
|
102
|
-
- !ruby/object:Gem::Version
|
103
|
-
version: 1.0.4
|
104
|
-
type: :runtime
|
105
|
-
prerelease: false
|
106
|
-
version_requirements: !ruby/object:Gem::Requirement
|
107
|
-
requirements:
|
108
|
-
- - "~>"
|
109
|
-
- !ruby/object:Gem::Version
|
110
|
-
version: 1.0.4
|
111
|
-
- !ruby/object:Gem::Dependency
|
112
|
-
name: sprockets
|
70
|
+
name: erubis
|
113
71
|
requirement: !ruby/object:Gem::Requirement
|
114
72
|
requirements:
|
115
|
-
- -
|
73
|
+
- - ~>
|
116
74
|
- !ruby/object:Gem::Version
|
117
|
-
version: 2.
|
75
|
+
version: 2.7.0
|
118
76
|
type: :runtime
|
119
77
|
prerelease: false
|
120
78
|
version_requirements: !ruby/object:Gem::Requirement
|
121
79
|
requirements:
|
122
|
-
- -
|
80
|
+
- - ~>
|
123
81
|
- !ruby/object:Gem::Version
|
124
|
-
version: 2.
|
82
|
+
version: 2.7.0
|
125
83
|
- !ruby/object:Gem::Dependency
|
126
|
-
name:
|
84
|
+
name: activemodel
|
127
85
|
requirement: !ruby/object:Gem::Requirement
|
128
86
|
requirements:
|
129
|
-
- -
|
87
|
+
- - '='
|
130
88
|
- !ruby/object:Gem::Version
|
131
|
-
version:
|
132
|
-
type: :
|
89
|
+
version: 4.0.0.beta1
|
90
|
+
type: :development
|
133
91
|
prerelease: false
|
134
92
|
version_requirements: !ruby/object:Gem::Requirement
|
135
93
|
requirements:
|
136
|
-
- -
|
94
|
+
- - '='
|
137
95
|
- !ruby/object:Gem::Version
|
138
|
-
version:
|
96
|
+
version: 4.0.0.beta1
|
139
97
|
- !ruby/object:Gem::Dependency
|
140
98
|
name: tzinfo
|
141
99
|
requirement: !ruby/object:Gem::Requirement
|
142
100
|
requirements:
|
143
|
-
- -
|
101
|
+
- - ~>
|
144
102
|
- !ruby/object:Gem::Version
|
145
|
-
version: 0.3.
|
103
|
+
version: 0.3.33
|
146
104
|
type: :development
|
147
105
|
prerelease: false
|
148
106
|
version_requirements: !ruby/object:Gem::Requirement
|
149
107
|
requirements:
|
150
|
-
- -
|
108
|
+
- - ~>
|
151
109
|
- !ruby/object:Gem::Version
|
152
|
-
version: 0.3.
|
110
|
+
version: 0.3.33
|
153
111
|
description: Web apps on Rails. Simple, battle-tested conventions for building and
|
154
112
|
testing MVC web applications. Works with any Rack-compatible server.
|
155
113
|
email: david@loudthinking.com
|
@@ -158,9 +116,8 @@ extensions: []
|
|
158
116
|
extra_rdoc_files: []
|
159
117
|
files:
|
160
118
|
- CHANGELOG.md
|
161
|
-
- MIT-LICENSE
|
162
119
|
- README.rdoc
|
163
|
-
-
|
120
|
+
- MIT-LICENSE
|
164
121
|
- lib/abstract_controller/asset_paths.rb
|
165
122
|
- lib/abstract_controller/base.rb
|
166
123
|
- lib/abstract_controller/callbacks.rb
|
@@ -173,19 +130,13 @@ files:
|
|
173
130
|
- lib/abstract_controller/translation.rb
|
174
131
|
- lib/abstract_controller/url_for.rb
|
175
132
|
- lib/abstract_controller/view_paths.rb
|
176
|
-
- lib/
|
133
|
+
- lib/abstract_controller.rb
|
177
134
|
- lib/action_controller/base.rb
|
178
|
-
- lib/action_controller/caching.rb
|
179
|
-
- lib/action_controller/caching/actions.rb
|
180
135
|
- lib/action_controller/caching/fragments.rb
|
181
|
-
- lib/action_controller/caching
|
182
|
-
- lib/action_controller/caching/sweeping.rb
|
183
|
-
- lib/action_controller/deprecated.rb
|
136
|
+
- lib/action_controller/caching.rb
|
184
137
|
- lib/action_controller/deprecated/integration_test.rb
|
185
|
-
- lib/action_controller/deprecated
|
138
|
+
- lib/action_controller/deprecated.rb
|
186
139
|
- lib/action_controller/log_subscriber.rb
|
187
|
-
- lib/action_controller/metal.rb
|
188
|
-
- lib/action_controller/metal/compatibility.rb
|
189
140
|
- lib/action_controller/metal/conditional_get.rb
|
190
141
|
- lib/action_controller/metal/cookies.rb
|
191
142
|
- lib/action_controller/metal/data_streaming.rb
|
@@ -198,6 +149,7 @@ files:
|
|
198
149
|
- lib/action_controller/metal/http_authentication.rb
|
199
150
|
- lib/action_controller/metal/implicit_render.rb
|
200
151
|
- lib/action_controller/metal/instrumentation.rb
|
152
|
+
- lib/action_controller/metal/live.rb
|
201
153
|
- lib/action_controller/metal/mime_responds.rb
|
202
154
|
- lib/action_controller/metal/params_wrapper.rb
|
203
155
|
- lib/action_controller/metal/rack_delegation.rb
|
@@ -207,25 +159,22 @@ files:
|
|
207
159
|
- lib/action_controller/metal/request_forgery_protection.rb
|
208
160
|
- lib/action_controller/metal/rescue.rb
|
209
161
|
- lib/action_controller/metal/responder.rb
|
210
|
-
- lib/action_controller/metal/session_management.rb
|
211
162
|
- lib/action_controller/metal/streaming.rb
|
163
|
+
- lib/action_controller/metal/strong_parameters.rb
|
212
164
|
- lib/action_controller/metal/testing.rb
|
213
165
|
- lib/action_controller/metal/url_for.rb
|
166
|
+
- lib/action_controller/metal.rb
|
214
167
|
- lib/action_controller/middleware.rb
|
168
|
+
- lib/action_controller/model_naming.rb
|
215
169
|
- lib/action_controller/railtie.rb
|
216
|
-
- lib/action_controller/railties/
|
170
|
+
- lib/action_controller/railties/helpers.rb
|
217
171
|
- lib/action_controller/record_identifier.rb
|
218
172
|
- lib/action_controller/test_case.rb
|
219
173
|
- lib/action_controller/vendor/html-scanner.rb
|
220
|
-
- lib/action_controller
|
221
|
-
- lib/action_controller/vendor/html-scanner/html/node.rb
|
222
|
-
- lib/action_controller/vendor/html-scanner/html/sanitizer.rb
|
223
|
-
- lib/action_controller/vendor/html-scanner/html/selector.rb
|
224
|
-
- lib/action_controller/vendor/html-scanner/html/tokenizer.rb
|
225
|
-
- lib/action_controller/vendor/html-scanner/html/version.rb
|
226
|
-
- lib/action_dispatch.rb
|
174
|
+
- lib/action_controller.rb
|
227
175
|
- lib/action_dispatch/http/cache.rb
|
228
176
|
- lib/action_dispatch/http/filter_parameters.rb
|
177
|
+
- lib/action_dispatch/http/filter_redirect.rb
|
229
178
|
- lib/action_dispatch/http/headers.rb
|
230
179
|
- lib/action_dispatch/http/mime_negotiation.rb
|
231
180
|
- lib/action_dispatch/http/mime_type.rb
|
@@ -237,28 +186,51 @@ files:
|
|
237
186
|
- lib/action_dispatch/http/response.rb
|
238
187
|
- lib/action_dispatch/http/upload.rb
|
239
188
|
- lib/action_dispatch/http/url.rb
|
240
|
-
- lib/action_dispatch/
|
241
|
-
- lib/action_dispatch/
|
189
|
+
- lib/action_dispatch/journey/backwards.rb
|
190
|
+
- lib/action_dispatch/journey/formatter.rb
|
191
|
+
- lib/action_dispatch/journey/gtg/builder.rb
|
192
|
+
- lib/action_dispatch/journey/gtg/simulator.rb
|
193
|
+
- lib/action_dispatch/journey/gtg/transition_table.rb
|
194
|
+
- lib/action_dispatch/journey/nfa/builder.rb
|
195
|
+
- lib/action_dispatch/journey/nfa/dot.rb
|
196
|
+
- lib/action_dispatch/journey/nfa/simulator.rb
|
197
|
+
- lib/action_dispatch/journey/nfa/transition_table.rb
|
198
|
+
- lib/action_dispatch/journey/nodes/node.rb
|
199
|
+
- lib/action_dispatch/journey/parser.rb
|
200
|
+
- lib/action_dispatch/journey/parser.y
|
201
|
+
- lib/action_dispatch/journey/parser_extras.rb
|
202
|
+
- lib/action_dispatch/journey/path/pattern.rb
|
203
|
+
- lib/action_dispatch/journey/route.rb
|
204
|
+
- lib/action_dispatch/journey/router/strexp.rb
|
205
|
+
- lib/action_dispatch/journey/router/utils.rb
|
206
|
+
- lib/action_dispatch/journey/router.rb
|
207
|
+
- lib/action_dispatch/journey/routes.rb
|
208
|
+
- lib/action_dispatch/journey/scanner.rb
|
209
|
+
- lib/action_dispatch/journey/visitors.rb
|
210
|
+
- lib/action_dispatch/journey/visualizer/fsm.css
|
211
|
+
- lib/action_dispatch/journey/visualizer/fsm.js
|
212
|
+
- lib/action_dispatch/journey/visualizer/index.html.erb
|
213
|
+
- lib/action_dispatch/journey.rb
|
242
214
|
- lib/action_dispatch/middleware/callbacks.rb
|
243
215
|
- lib/action_dispatch/middleware/cookies.rb
|
244
216
|
- lib/action_dispatch/middleware/debug_exceptions.rb
|
245
217
|
- lib/action_dispatch/middleware/exception_wrapper.rb
|
246
218
|
- lib/action_dispatch/middleware/flash.rb
|
247
|
-
- lib/action_dispatch/middleware/head.rb
|
248
219
|
- lib/action_dispatch/middleware/params_parser.rb
|
249
220
|
- lib/action_dispatch/middleware/public_exceptions.rb
|
250
221
|
- lib/action_dispatch/middleware/reloader.rb
|
251
222
|
- lib/action_dispatch/middleware/remote_ip.rb
|
252
223
|
- lib/action_dispatch/middleware/request_id.rb
|
253
|
-
- lib/action_dispatch/middleware/rescue.rb
|
254
224
|
- lib/action_dispatch/middleware/session/abstract_store.rb
|
255
225
|
- lib/action_dispatch/middleware/session/cache_store.rb
|
256
226
|
- lib/action_dispatch/middleware/session/cookie_store.rb
|
257
227
|
- lib/action_dispatch/middleware/session/mem_cache_store.rb
|
258
228
|
- lib/action_dispatch/middleware/show_exceptions.rb
|
229
|
+
- lib/action_dispatch/middleware/ssl.rb
|
259
230
|
- lib/action_dispatch/middleware/stack.rb
|
260
231
|
- lib/action_dispatch/middleware/static.rb
|
261
232
|
- lib/action_dispatch/middleware/templates/rescues/_request_and_response.erb
|
233
|
+
- lib/action_dispatch/middleware/templates/rescues/_source.erb
|
262
234
|
- lib/action_dispatch/middleware/templates/rescues/_trace.erb
|
263
235
|
- lib/action_dispatch/middleware/templates/rescues/diagnostics.erb
|
264
236
|
- lib/action_dispatch/middleware/templates/rescues/layout.erb
|
@@ -266,41 +238,40 @@ files:
|
|
266
238
|
- lib/action_dispatch/middleware/templates/rescues/routing_error.erb
|
267
239
|
- lib/action_dispatch/middleware/templates/rescues/template_error.erb
|
268
240
|
- lib/action_dispatch/middleware/templates/rescues/unknown_action.erb
|
241
|
+
- lib/action_dispatch/middleware/templates/routes/_route.html.erb
|
242
|
+
- lib/action_dispatch/middleware/templates/routes/_table.html.erb
|
269
243
|
- lib/action_dispatch/railtie.rb
|
270
|
-
- lib/action_dispatch/
|
244
|
+
- lib/action_dispatch/request/session.rb
|
245
|
+
- lib/action_dispatch/routing/inspector.rb
|
271
246
|
- lib/action_dispatch/routing/mapper.rb
|
272
247
|
- lib/action_dispatch/routing/polymorphic_routes.rb
|
273
248
|
- lib/action_dispatch/routing/redirection.rb
|
274
249
|
- lib/action_dispatch/routing/route_set.rb
|
275
250
|
- lib/action_dispatch/routing/routes_proxy.rb
|
276
251
|
- lib/action_dispatch/routing/url_for.rb
|
277
|
-
- lib/action_dispatch/
|
252
|
+
- lib/action_dispatch/routing.rb
|
278
253
|
- lib/action_dispatch/testing/assertions/dom.rb
|
279
254
|
- lib/action_dispatch/testing/assertions/response.rb
|
280
255
|
- lib/action_dispatch/testing/assertions/routing.rb
|
281
256
|
- lib/action_dispatch/testing/assertions/selector.rb
|
282
257
|
- lib/action_dispatch/testing/assertions/tag.rb
|
258
|
+
- lib/action_dispatch/testing/assertions.rb
|
283
259
|
- lib/action_dispatch/testing/integration.rb
|
284
|
-
- lib/action_dispatch/testing/performance_test.rb
|
285
260
|
- lib/action_dispatch/testing/test_process.rb
|
286
261
|
- lib/action_dispatch/testing/test_request.rb
|
287
262
|
- lib/action_dispatch/testing/test_response.rb
|
288
|
-
- lib/
|
263
|
+
- lib/action_dispatch.rb
|
289
264
|
- lib/action_pack/version.rb
|
290
|
-
- lib/
|
291
|
-
- lib/action_view/asset_paths.rb
|
265
|
+
- lib/action_pack.rb
|
292
266
|
- lib/action_view/base.rb
|
293
267
|
- lib/action_view/buffers.rb
|
294
268
|
- lib/action_view/context.rb
|
269
|
+
- lib/action_view/dependency_tracker.rb
|
270
|
+
- lib/action_view/digestor.rb
|
295
271
|
- lib/action_view/flows.rb
|
296
|
-
- lib/action_view/helpers.rb
|
297
272
|
- lib/action_view/helpers/active_model_helper.rb
|
298
|
-
- lib/action_view/helpers/asset_paths.rb
|
299
273
|
- lib/action_view/helpers/asset_tag_helper.rb
|
300
|
-
- lib/action_view/helpers/
|
301
|
-
- lib/action_view/helpers/asset_tag_helpers/asset_paths.rb
|
302
|
-
- lib/action_view/helpers/asset_tag_helpers/javascript_tag_helpers.rb
|
303
|
-
- lib/action_view/helpers/asset_tag_helpers/stylesheet_tag_helpers.rb
|
274
|
+
- lib/action_view/helpers/asset_url_helper.rb
|
304
275
|
- lib/action_view/helpers/atom_feed_helper.rb
|
305
276
|
- lib/action_view/helpers/cache_helper.rb
|
306
277
|
- lib/action_view/helpers/capture_helper.rb
|
@@ -318,36 +289,76 @@ files:
|
|
318
289
|
- lib/action_view/helpers/rendering_helper.rb
|
319
290
|
- lib/action_view/helpers/sanitize_helper.rb
|
320
291
|
- lib/action_view/helpers/tag_helper.rb
|
292
|
+
- lib/action_view/helpers/tags/base.rb
|
293
|
+
- lib/action_view/helpers/tags/check_box.rb
|
294
|
+
- lib/action_view/helpers/tags/checkable.rb
|
295
|
+
- lib/action_view/helpers/tags/collection_check_boxes.rb
|
296
|
+
- lib/action_view/helpers/tags/collection_helpers.rb
|
297
|
+
- lib/action_view/helpers/tags/collection_radio_buttons.rb
|
298
|
+
- lib/action_view/helpers/tags/collection_select.rb
|
299
|
+
- lib/action_view/helpers/tags/color_field.rb
|
300
|
+
- lib/action_view/helpers/tags/date_field.rb
|
301
|
+
- lib/action_view/helpers/tags/date_select.rb
|
302
|
+
- lib/action_view/helpers/tags/datetime_field.rb
|
303
|
+
- lib/action_view/helpers/tags/datetime_local_field.rb
|
304
|
+
- lib/action_view/helpers/tags/datetime_select.rb
|
305
|
+
- lib/action_view/helpers/tags/email_field.rb
|
306
|
+
- lib/action_view/helpers/tags/file_field.rb
|
307
|
+
- lib/action_view/helpers/tags/grouped_collection_select.rb
|
308
|
+
- lib/action_view/helpers/tags/hidden_field.rb
|
309
|
+
- lib/action_view/helpers/tags/label.rb
|
310
|
+
- lib/action_view/helpers/tags/month_field.rb
|
311
|
+
- lib/action_view/helpers/tags/number_field.rb
|
312
|
+
- lib/action_view/helpers/tags/password_field.rb
|
313
|
+
- lib/action_view/helpers/tags/radio_button.rb
|
314
|
+
- lib/action_view/helpers/tags/range_field.rb
|
315
|
+
- lib/action_view/helpers/tags/search_field.rb
|
316
|
+
- lib/action_view/helpers/tags/select.rb
|
317
|
+
- lib/action_view/helpers/tags/tel_field.rb
|
318
|
+
- lib/action_view/helpers/tags/text_area.rb
|
319
|
+
- lib/action_view/helpers/tags/text_field.rb
|
320
|
+
- lib/action_view/helpers/tags/time_field.rb
|
321
|
+
- lib/action_view/helpers/tags/time_select.rb
|
322
|
+
- lib/action_view/helpers/tags/time_zone_select.rb
|
323
|
+
- lib/action_view/helpers/tags/url_field.rb
|
324
|
+
- lib/action_view/helpers/tags/week_field.rb
|
325
|
+
- lib/action_view/helpers/tags.rb
|
321
326
|
- lib/action_view/helpers/text_helper.rb
|
322
327
|
- lib/action_view/helpers/translation_helper.rb
|
323
328
|
- lib/action_view/helpers/url_helper.rb
|
329
|
+
- lib/action_view/helpers.rb
|
324
330
|
- lib/action_view/locale/en.yml
|
325
331
|
- lib/action_view/log_subscriber.rb
|
326
332
|
- lib/action_view/lookup_context.rb
|
333
|
+
- lib/action_view/model_naming.rb
|
327
334
|
- lib/action_view/path_set.rb
|
328
335
|
- lib/action_view/railtie.rb
|
336
|
+
- lib/action_view/record_identifier.rb
|
329
337
|
- lib/action_view/renderer/abstract_renderer.rb
|
330
338
|
- lib/action_view/renderer/partial_renderer.rb
|
331
339
|
- lib/action_view/renderer/renderer.rb
|
332
340
|
- lib/action_view/renderer/streaming_template_renderer.rb
|
333
341
|
- lib/action_view/renderer/template_renderer.rb
|
334
|
-
- lib/action_view/
|
342
|
+
- lib/action_view/routing_url_for.rb
|
335
343
|
- lib/action_view/template/error.rb
|
336
|
-
- lib/action_view/template/handlers.rb
|
337
344
|
- lib/action_view/template/handlers/builder.rb
|
338
345
|
- lib/action_view/template/handlers/erb.rb
|
346
|
+
- lib/action_view/template/handlers/raw.rb
|
347
|
+
- lib/action_view/template/handlers.rb
|
339
348
|
- lib/action_view/template/resolver.rb
|
340
349
|
- lib/action_view/template/text.rb
|
350
|
+
- lib/action_view/template/types.rb
|
351
|
+
- lib/action_view/template.rb
|
341
352
|
- lib/action_view/test_case.rb
|
342
353
|
- lib/action_view/testing/resolvers.rb
|
343
|
-
- lib/
|
344
|
-
- lib/
|
345
|
-
- lib/
|
346
|
-
- lib/
|
347
|
-
- lib/
|
348
|
-
- lib/
|
349
|
-
- lib/
|
350
|
-
- lib/
|
354
|
+
- lib/action_view/vendor/html-scanner/html/document.rb
|
355
|
+
- lib/action_view/vendor/html-scanner/html/node.rb
|
356
|
+
- lib/action_view/vendor/html-scanner/html/sanitizer.rb
|
357
|
+
- lib/action_view/vendor/html-scanner/html/selector.rb
|
358
|
+
- lib/action_view/vendor/html-scanner/html/tokenizer.rb
|
359
|
+
- lib/action_view/vendor/html-scanner/html/version.rb
|
360
|
+
- lib/action_view/vendor/html-scanner.rb
|
361
|
+
- lib/action_view.rb
|
351
362
|
homepage: http://www.rubyonrails.org
|
352
363
|
licenses:
|
353
364
|
- MIT
|
@@ -358,20 +369,19 @@ require_paths:
|
|
358
369
|
- lib
|
359
370
|
required_ruby_version: !ruby/object:Gem::Requirement
|
360
371
|
requirements:
|
361
|
-
- -
|
372
|
+
- - '>='
|
362
373
|
- !ruby/object:Gem::Version
|
363
|
-
version: 1.
|
374
|
+
version: 1.9.3
|
364
375
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
365
376
|
requirements:
|
366
|
-
- -
|
377
|
+
- - '>'
|
367
378
|
- !ruby/object:Gem::Version
|
368
|
-
version:
|
379
|
+
version: 1.3.1
|
369
380
|
requirements:
|
370
381
|
- none
|
371
382
|
rubyforge_project:
|
372
|
-
rubygems_version: 2.
|
383
|
+
rubygems_version: 2.0.0
|
373
384
|
signing_key:
|
374
385
|
specification_version: 4
|
375
386
|
summary: Web-flow and rendering framework putting the VC in MVC (part of Rails).
|
376
387
|
test_files: []
|
377
|
-
has_rdoc:
|