Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add doc about I18n support for :placeholder option [ci skip] #37054

Merged

Conversation

sinsoku
Copy link
Contributor

@sinsoku sinsoku commented Aug 27, 2019

The :placeholder option accepts true, so it should be mentioned in the documentation.

Ref: #16438

@rails-bot rails-bot bot added the actionview label Aug 27, 2019
@@ -165,7 +165,7 @@ def select_tag(name, option_tags = nil, options = {})
# * <tt>:disabled</tt> - If set to true, the user will not be able to use this input.
# * <tt>:size</tt> - The number of visible characters that will fit in the input.
# * <tt>:maxlength</tt> - The maximum number of characters that the browser will allow the user to enter.
# * <tt>:placeholder</tt> - The text contained in the field by default which is removed when the field receives focus.
# * <tt>:placeholder</tt> - The text contained in the field by default which is removed when the field receives focus. If set to true, use a translation is found in the current I18n locale (through helpers.placeholders.<modelname>.<attribute>).
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can you fix this to wrap at 80 characters? Don't update the rest of the file, just the new docs you added. Thanks!

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you for your review. I added a line break and did fource-push.

The :placeholder option accepts true, so it should be mentioned in the documentation.

Ref: rails#16438
@sinsoku sinsoku force-pushed the patch/add_doc_for_placeholder_option branch from b7d6a84 to 7b157f1 Compare August 27, 2019 17:26
@eileencodes eileencodes merged commit ead5331 into rails:master Aug 27, 2019
eileencodes added a commit that referenced this pull request Aug 27, 2019
…option

Add doc about I18n support for :placeholder option [ci skip]
eileencodes added a commit that referenced this pull request Aug 27, 2019
…option

Add doc about I18n support for :placeholder option [ci skip]
@eileencodes
Copy link
Member

Backported to 6-0-stable and 5-2-stable

@@ -166,6 +166,8 @@ def select_tag(name, option_tags = nil, options = {})
# * <tt>:size</tt> - The number of visible characters that will fit in the input.
# * <tt>:maxlength</tt> - The maximum number of characters that the browser will allow the user to enter.
# * <tt>:placeholder</tt> - The text contained in the field by default which is removed when the field receives focus.
# If set to true, use a translation is found in the current I18n locale
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

use a translation is found in
->
use the translation found in

JesseChavez pushed a commit to JesseChavez/rails that referenced this pull request Dec 19, 2019
…lder_option

Add doc about I18n support for :placeholder option [ci skip]
@sinsoku sinsoku deleted the patch/add_doc_for_placeholder_option branch January 25, 2021 09:17
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants