New issue
Advanced search Search tips

Issue 915651 link

Starred by 1 user

Issue metadata

Status: Fixed
Owner:
Closed: Dec 18
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: ----
Pri: 1
Type: Bug



Sign in to add a comment

User Remove Warning Part2 i18n message $1 placeholder should be wrapped in a <ph> element

Project Member Reported by noel@chromium.org, Dec 17

Issue description

https://chromium-review.googlesource.com/c/chromium/src/+/930242 added an i18n message

./ash/ash_strings.grd
  string IDS_ASH_LOGIN_POD_NON_OWNER_USER_REMOVE_WARNING_PART_2
   "$1 can still sign in later."

Placeholder elements like $1 $2, should be wrapped in <ph> elements according to the docs [1] [2]

[1] https://sites.google.com/a/chromium.org/dev/developers/design-documents/ui-localization#TOC-How-to-add-a-string
[2] https://sites.google.com/a/chromium.org/dev/developers/tools-we-use-in-chromium/grit/grit-users-guide#Adding_Resources

along with and <ex> element giving an example.

   <ph name="USER_EMAIL">$2<ex>foo@example.com</ex></ph>

When this is not done, applications can fail to work when reading the i18n translated strings, sadly.

Can we please fix?
 
Labels: bad-i18n-placeholders
Cc: jdufault@chromium.org
Owner: noel@chromium.org
Hmmm, reading https://chromium-review.googlesource.com/c/chromium/src/+/930242 closer the place seems to be an email address ...  lemme fix.
Cc: -jdufault@chromium.org
Owner: jdufault@chromium.org
Status: Started (was: Untriaged)
Upload a patch and see a merger conflict :).  Marking started ...
Project Member

Comment 4 by bugdroid1@chromium.org, Dec 18

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/8cc396cb46ee2c18bf43cd56393b29bb67375f0f

commit 8cc396cb46ee2c18bf43cd56393b29bb67375f0f
Author: Jacob Dufault <jdufault@google.com>
Date: Tue Dec 18 20:10:55 2018

cros: Update string to use <ph> instead of directly embedding $1

Bug:  915651 
Change-Id: I2018d601247f393c2ef4fc9d59cbfee7fcd19f8e
Reviewed-on: https://chromium-review.googlesource.com/c/1380537
Commit-Queue: Jacob Dufault <jdufault@chromium.org>
Reviewed-by: Quan Nguyen <qnnguyen@chromium.org>
Cr-Commit-Position: refs/heads/master@{#617601}
[modify] https://crrev.com/8cc396cb46ee2c18bf43cd56393b29bb67375f0f/ash/ash_strings.grd

Status: Fixed (was: Started)
jdufault@ Thank you for fixing this so quickly.

Sign in to add a comment