Closed Bug 1600134 Opened 3 months ago Closed 2 months ago

Refactor get_translations_from_other_locales() API

Categories

(Webtools :: Pontoon, enhancement, P3)

enhancement

Tracking

(Not tracked)

RESOLVED FIXED

People

(Reporter: mathjazz, Assigned: abowler2, Mentored)

References

Details

(Whiteboard: outreachyround19)

Attachments

(2 files)

get_translations_from_other_locales() method should return a dict with two lists:

  • translations to preferred locales
  • translations to other locales

That way we can simplify the frontend code and remove:

  • preferred_locales from the user_data() method
  • UserProfile.sorted_locales_codes
  • otherlocales.selectors.getOrderedOtherLocales

If translation from a preferred_source_locale is displayed instead of the actual original string, we should add the original string to the top of the preferred list. We should render it as an en-US translation until bug 1328879 gets fixed, and make sure it isn't linked like translations from other locales.

Assignee: nobody → abowler2
Mentor: m
Status: NEW → RESOLVED
Closed: 2 months ago
Resolution: --- → FIXED
Whiteboard: outreachyround19
You need to log in before you can comment on or make changes to this bug.