codeforboston/maple

i18n Text Translations: publish components

Open

#1.141 geöffnet am 10. Mai 2023

Auf GitHub ansehen
 (2 Kommentare) (0 Reaktionen) (1 zugewiesene Person)TypeScript (168 Forks)auto 404
Public Launchgood first issuei18n

Repository-Metriken

Stars
 (56 Stars)
PR-Merge-Metriken
 (PR-Metriken ausstehend)

Beschreibung

Files:

components Publish/Panel ArchiveTestitmonyConfirmation
components Publish/Panel ctas
components Publish/Panel ThankYouModal
components Publish/Panel YourTestimony
components Publish ChooseStance
components Publish content
components Publish ProgressBar
components Publish PublishInfo
components Publish PublishTestimony
components Publish QuickInfo
components Publish SelectLegislators
components Publish SelectRecipients
components Publish SendEmailButton
components Publish ShareTestimony
components Publish SubmitTestimony
components Publish SyncStatus
components Publish TestimonyPreview
components Publish WriteTestimony
  • Move user-visible text from these section into json files in the public/locales/en folder; use the next-i18next 'useTranslation' hook to connect the text from the json files
  • You'll decide how to group and name your text in a way that makes sense for your section by default, make separate json files following the structure of the project pages/folders, but feel free to diverge from that if needed.
  • make sure to get titles, headers, buttons, labels, and alt text
  • Put common words, labels, etc in the common.json file
  • At this time, don’t worry about translating content on the files in the pages folder itself at this time, but you will need to update these files to include the json files you created.
  • some pages may have already been extracted more or less into files next to or near the component files, usually with the same file name with 'content' on the end. That text needs to be moved as above, and it's up to you what to do with the content file.

Contributor Guide