Skip to content

Part 3: adding logic to translate on rails side - #51063

Merged
hannahbergam merged 3 commits into
stagingfrom
hbergam/quickAssignTranslations
Apr 7, 2023
Merged

Part 3: adding logic to translate on rails side#51063
hannahbergam merged 3 commits into
stagingfrom
hbergam/quickAssignTranslations

Conversation

@hannahbergam

@hannahbergam hannahbergam commented Mar 31, 2023

Copy link
Copy Markdown
Contributor

This completes the work started in #51056 and #51055, which adds translations for course offering headers.

I am translating these on the rails side with inspiration from localized_display_name.

The default:nil ensures that a failed translation returns the original header instead of the translation error message. This also allows us to keep the test cases the same.

Here are some photos to help show that these headers are indeed pulling from the en.yml file. This is not code I've committed- it's just for testing purposes

I changed the labs and skills header to 'Test Header' in the translations file to see if it would appear on the page, and it does:
Screenshot 2023-04-05 at 10 32 34 AM

Screenshot 2023-04-05 at 10 33 03 AM

Links

Testing story

Deployment strategy

Follow-up work

Privacy

Security

Caching

PR Checklist:

  • Tests provide adequate coverage
  • Privacy and Security impacts have been assessed
  • Code is well-commented
  • New features are translatable or updates will not break translations
  • Relevant documentation has been added or updated
  • User impact is well-understood and desirable
  • Pull Request is labeled appropriately
  • Follow-up work items (including potential tech debt) are tracked and linked

@hannahbergam
hannahbergam marked this pull request as ready for review April 4, 2023 22:12
@hannahbergam
hannahbergam requested a review from a team April 5, 2023 17:35

@bethanyaconnor bethanyaconnor left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🎉 thanks for sticking with this!

@hannahbergam
hannahbergam merged commit bc559fd into staging Apr 7, 2023
@hannahbergam
hannahbergam deleted the hbergam/quickAssignTranslations branch April 7, 2023 14:41
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants