aboutsummaryrefslogtreecommitdiffstats
path: root/actionview/lib/action_view/helpers/date_helper.rb
diff options
context:
space:
mode:
Diffstat (limited to 'actionview/lib/action_view/helpers/date_helper.rb')
-rw-r--r--actionview/lib/action_view/helpers/date_helper.rb16
1 files changed, 8 insertions, 8 deletions
diff --git a/actionview/lib/action_view/helpers/date_helper.rb b/actionview/lib/action_view/helpers/date_helper.rb
index ecdad14f90..9d5e5eaba3 100644
--- a/actionview/lib/action_view/helpers/date_helper.rb
+++ b/actionview/lib/action_view/helpers/date_helper.rb
@@ -684,7 +684,7 @@ module ActionView
format = options.delete(:format) || :long
content = args.first || I18n.l(date_or_time, format: format)
- content_tag("time".freeze, content, options.reverse_merge(datetime: date_or_time.iso8601), &block)
+ content_tag("time", content, options.reverse_merge(datetime: date_or_time.iso8601), &block)
end
private
@@ -703,7 +703,7 @@ module ActionView
class DateTimeSelector #:nodoc:
include ActionView::Helpers::TagHelper
- DEFAULT_PREFIX = "date".freeze
+ DEFAULT_PREFIX = "date"
POSITION = {
year: 1, month: 2, day: 3, hour: 4, minute: 5, second: 6
}.freeze
@@ -824,7 +824,7 @@ module ActionView
1.upto(12) do |month_number|
options = { value: month_number }
options[:selected] = "selected" if month == month_number
- month_options << content_tag("option".freeze, month_name(month_number), options) + "\n"
+ month_options << content_tag("option", month_name(month_number), options) + "\n"
end
build_select(:month, month_options.join)
end
@@ -1006,7 +1006,7 @@ module ActionView
tag_options[:selected] = "selected" if selected == i
text = options[:use_two_digit_numbers] ? sprintf("%02d", i) : value
text = options[:ampm] ? AMPM_TRANSLATION[i] : text
- select_options << content_tag("option".freeze, text, tag_options)
+ select_options << content_tag("option", text, tag_options)
end
(select_options.join("\n") + "\n").html_safe
@@ -1034,7 +1034,7 @@ module ActionView
tag_options = { value: value }
tag_options[:selected] = "selected" if selected == value
text = year_name(value)
- select_options << content_tag("option".freeze, text, tag_options)
+ select_options << content_tag("option", text, tag_options)
end
(select_options.join("\n") + "\n").html_safe
@@ -1054,11 +1054,11 @@ module ActionView
select_options[:class] = css_class_attribute(type, select_options[:class], @options[:with_css_classes]) if @options[:with_css_classes]
select_html = +"\n"
- select_html << content_tag("option".freeze, "", value: "") + "\n" if @options[:include_blank]
+ select_html << content_tag("option", "", value: "") + "\n" if @options[:include_blank]
select_html << prompt_option_tag(type, @options[:prompt]) + "\n" if @options[:prompt]
select_html << select_options_as_html
- (content_tag("select".freeze, select_html.html_safe, select_options) + "\n").html_safe
+ (content_tag("select", select_html.html_safe, select_options) + "\n").html_safe
end
# Builds the css class value for the select element
@@ -1091,7 +1091,7 @@ module ActionView
I18n.translate(:"datetime.prompts.#{type}", locale: @options[:locale])
end
- prompt ? content_tag("option".freeze, prompt, value: "") : ""
+ prompt ? content_tag("option", prompt, value: "") : ""
end
# Builds hidden input tag for date part and value.