Sha256: 6d42a7e887710825581becca02552e1aab4760fa2c6e913901e34960e2340923
Contents?: true
Size: 666 Bytes
Versions: 44
Compression:
Stored size: 666 Bytes
Contents
module ActionView module Helpers module Tags # :nodoc: module Placeholderable # :nodoc: def initialize(*) super if tag_value = @options[:placeholder] placeholder = tag_value if tag_value.is_a?(String) method_and_value = tag_value.is_a?(TrueClass) ? @method_name : "#{@method_name}.#{tag_value}" placeholder ||= Tags::Translator .new(object, @object_name, method_and_value, "helpers.placeholder") .translate placeholder ||= @method_name.humanize @options[:placeholder] = placeholder end end end end end end
Version data entries
44 entries across 43 versions & 8 rubygems