diff options
author | Abhay Nikam <nikam.abhay1@gmail.com> | 2019-02-21 22:13:57 +0530 |
---|---|---|
committer | Abhay Nikam <nikam.abhay1@gmail.com> | 2019-02-22 10:18:21 +0530 |
commit | b3778c5708f430da968e2a6995741fc082e92156 (patch) | |
tree | 659bb4d4d02d885decbf359c25e1bac10ae0f762 /actiontext/app/helpers/action_text | |
parent | 3b6602aa7a01fb415fce07ef32458b131e5762e1 (diff) | |
download | rails-b3778c5708f430da968e2a6995741fc082e92156.tar.gz rails-b3778c5708f430da968e2a6995741fc082e92156.tar.bz2 rails-b3778c5708f430da968e2a6995741fc082e92156.zip |
Allows rich_text_area_tag to add I18n translated placeholder text if placeholder option set to true
Diffstat (limited to 'actiontext/app/helpers/action_text')
-rw-r--r-- | actiontext/app/helpers/action_text/tag_helper.rb | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/actiontext/app/helpers/action_text/tag_helper.rb b/actiontext/app/helpers/action_text/tag_helper.rb index 8434f2c611..1dc6202ae1 100644 --- a/actiontext/app/helpers/action_text/tag_helper.rb +++ b/actiontext/app/helpers/action_text/tag_helper.rb @@ -1,5 +1,7 @@ # frozen_string_literal: true +require "action_view/helpers/tags/placeholderable" + module ActionText module TagHelper cattr_accessor(:id, instance_accessor: false) { 0 } @@ -35,6 +37,8 @@ end module ActionView::Helpers class Tags::ActionText < Tags::Base + include Tags::Placeholderable + delegate :dom_id, to: ActionView::RecordIdentifier def render |