Bug 1970604 - Add IDP menu items are not translated
Summary: Add IDP menu items are not translated
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: OpenShift Container Platform
Classification: Red Hat
Component: Management Console
Version: 4.8
Hardware: Unspecified
OS: Unspecified
low
low
Target Milestone: ---
: 4.9.0
Assignee: Cyril
QA Contact: Yanping Zhang
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2021-06-10 18:58 UTC by Samuel Padgett
Modified: 2021-10-18 17:34 UTC (History)
4 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Cause: Incorrect code Consequence: The IDP menu items were not translated Fix: Split the keys from the displayed values using switch statement. Result: The IDP menu items are translated
Clone Of:
Environment:
Version: 4.8.0-0.nightly-2021-06-10-045932 Cluster ID: b0ec356e-83e7-4588-82cd-db5006b16bd4 Browser: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.15; rv:89.0) Gecko/20100101 Firefox/89.0
Last Closed: 2021-10-18 17:33:48 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)
ja translation file (1.36 MB, image/png)
2021-06-16 20:37 UTC, Cyril
no flags Details


Links
System ID Private Priority Status Summary Last Updated
Github openshift console pull 9308 0 None open Bug 1970604: Add IDP menu items are not translated 2021-06-21 20:07:06 UTC
Red Hat Product Errata RHSA-2021:3759 0 None None None 2021-10-18 17:34:08 UTC

Description Samuel Padgett 2021-06-10 18:58:29 UTC
The IDP items on the OAuth config details page aren't properly enabled for translation. They will always show up as English. See the code here:

https://github.com/spadgett/console/blob/ded0de8063bec2e02a07defeb1a050f4c9bf0399/frontend/public/components/cluster-settings/oauth.tsx#L50-L89

`{{label}}` will always evaluate to the English value set in the map from just above.

Comment 1 Cyril 2021-06-16 20:34:54 UTC
ralpert The IDP menu items are missing translation for other languages. Could you please help to get the translation file updated?

Comment 2 Cyril 2021-06-16 20:37:34 UTC
Created attachment 1791596 [details]
ja translation file

Comment 3 ralpert 2021-06-17 13:58:16 UTC
Hey @cajieh - Sorry I missed this yesterday. I think the issue here is that even though we're generating keys with the comments (//t('public~Request Header') and so on), we don't actually internationalize the values in the application. We're just passing these hard-coded English values in.

Sometimes the translators will prefer to leave proper nouns like Google in English, but I can see that they did translate a few of the terms. With the way the code is now, we won't ever seem those.

Comment 5 Yanping Zhang 2021-06-23 09:02:44 UTC
Checked on ocp 4.9 cluster with payload 4.9.0-0.nightly-2021-06-22-193627, now the add idp menu are translated in Chinese/Japanese/Korean, but "OpenID Connect" string in menu and on adding page are not translated in Japanese. Will we add the translation for it?

Comment 8 ralpert 2021-06-23 13:32:21 UTC
Hey @yanpzhan - It looks like Aiko intentionally left that in English.

Comment 9 Cyril 2021-06-23 13:58:00 UTC
@ralpert Thanks for responding to the query.

Comment 10 Cyril 2021-06-28 14:26:13 UTC
@yanpzhan - Please retest this fix.

Comment 11 Yanping Zhang 2021-06-30 02:40:19 UTC
According to Comment 8, the "OpenID Connect" string is intentionally kept in English, there is no other doubts about the fix, so move the bug to Verified.

Comment 14 errata-xmlrpc 2021-10-18 17:33:48 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory (Moderate: OpenShift Container Platform 4.9.0 bug fix and security update), and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://access.redhat.com/errata/RHSA-2021:3759


Note You need to log in before you can comment on or make changes to this bug.