-
Feature
-
Resolution: Won't Do
-
Minor
-
None
-
1
-
COST-1414UX continuous improvements: Provide the best usage experience for the different personas using cost management and the rest of the applications in cloud.redhat.com
-
subs-cost
Copied from https://github.com/project-koku/koku/issues/2104, which was originally presented as a bug. I am pitching it here as a possible broader internationalization/localization feature? soconcar@redhat.com I don't mean to crowd your feature usage, but just wanted to bring this to your attention and see what you think?
The UI currently localizes metric labels obtained from the cost-model API. For example, the `node currency rate` i18n key below appears to be one of these metric labels.
UI price list i18n strings:
```
"price_list": {
"modal": {
"cluster currency rate": "Cluster price rate tier index ({{ unit }})",
"cpu request rate": "CPU request rate tier {{ index }} ({{ unit }})",
"cpu usage rate": "CPU usage rate tier {{ index }} ({{ unit }})",
"memory request rate": "Memory request rate tier {{ index }} ({{ unit }})",
"memory usage rate": "Memory usage rate tier {{ index }} ({{ unit }})",
"node currency rate": "Node price rate tier index ({{ unit }})",
"storage request rate": "Storage request rate tier {{ index }} ({{ unit }})",
"storage usage rate": "Storage usage rate tier {{ index }} ({{ unit }})",
"volume request rate": "Volume request rate tier {{ index }} ({{ unit }})",
"volume usage rate": "Volume usage rate tier {{ index }} ({{ unit }})"
}
},
```
Unfortunately, when the API labels change, or a new metric is added, this approach breaks the UI. We need to refactor the UI so we don't depend on API labels as i18n keys. However, the API should localize its own strings.
Related: https://github.com/project-koku/koku-ui/issues/1537