New issue
Advanced search Search tips

Issue 915563 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

Extensions Directory dialog i18n message file $1 $2 placeholders should be wrapped in a <ph> element

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

Issue description

Refer to chrome/app/generated_resources.grd

string IDS_EXTENSIONS_DIRECTORY_CONFIRMATION_DIALOG_MESSAGE_READ_ONLY    ".. you want to grant "$1" permanent read access to this folder?"  string string IDS_EXTENSIONS_DIRECTORY_CONFIRMATION_DIALOG_MESSAGE_WRITABLE    "..you want to grant "$1" permanent write access to this folder?"

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 an <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.

There are 9 instances of this error in generated_resources.grd.  Can we please fix?

 
Ahem > There are 2 instances of this error ...
Labels: bad-i18n-placeholders
Project Member

Comment 3 by bugdroid1@chromium.org, Dec 18

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

commit e009db17ad54fe47cf396bc7efcc4c9553bf0ffe
Author: Sam McNally <sammc@chromium.org>
Date: Tue Dec 18 00:58:26 2018

Wrap directory access confirmation dialog string placeholders in <ph>.

String resources should wrap their placeholders in <ph> tags.
IDS_EXTENSIONS_DIRECTORY_CONFIRMATION_DIALOG_MESSAGE_READ_ONLY and
IDS_EXTENSIONS_DIRECTORY_CONFIRMATION_DIALOG_MESSAGE_WRITABLE currently
do not.

Bug:  915563 
Change-Id: I8b24c89a7deb97f972abfc511a252d9c6797f5d5
Reviewed-on: https://chromium-review.googlesource.com/c/1379603
Reviewed-by: Noel Gordon <noel@chromium.org>
Commit-Queue: Sam McNally <sammc@chromium.org>
Cr-Commit-Position: refs/heads/master@{#617319}
[modify] https://crrev.com/e009db17ad54fe47cf396bc7efcc4c9553bf0ffe/chrome/app/generated_resources.grd

Status: Fixed (was: Untriaged)
Sam mentioned he did manual verification of this change at ToT chrome, so marking fixed for now.
Summary: Extensions Directory dialog i18n message file $1 $2 placeholders should be wrapped in a <ph> element (was: Extensions Directory dialog i18n message file $1 $2 place holders should be wrapped in a <ph> element)

Sign in to add a comment