-
Notifications
You must be signed in to change notification settings - Fork 107
[Bug:] i18n appears to be broken #4094
Copy link
Copy link
Open
Labels
Impacts: CoreImpacts the core DS primarily, changes may occur in other themes as well.Impacts the core DS primarily, changes may occur in other themes as well.Impacts: DocumentationIndicates that this item relates to documentationIndicates that this item relates to documentationImpacts: HealthcareImpacts the Healthcare.gov theme directly.Impacts the Healthcare.gov theme directly.Impacts: MedicareImpacts the Medicare theme directly.Impacts the Medicare theme directly.Status: In JIRAIndicates that this item is also tracked in JiraIndicates that this item is also tracked in JiraStatus: Work In ProgressPR's that are not yet ready for reviewPR's that are not yet ready for reviewdependenciesPull requests that update a dependency filePull requests that update a dependency filejavascriptPull requests that update javascript codePull requests that update javascript code
Description
Metadata
Metadata
Assignees
Labels
Impacts: CoreImpacts the core DS primarily, changes may occur in other themes as well.Impacts the core DS primarily, changes may occur in other themes as well.Impacts: DocumentationIndicates that this item relates to documentationIndicates that this item relates to documentationImpacts: HealthcareImpacts the Healthcare.gov theme directly.Impacts the Healthcare.gov theme directly.Impacts: MedicareImpacts the Medicare theme directly.Impacts the Medicare theme directly.Status: In JIRAIndicates that this item is also tracked in JiraIndicates that this item is also tracked in JiraStatus: Work In ProgressPR's that are not yet ready for reviewPR's that are not yet ready for reviewdependenciesPull requests that update a dependency filePull requests that update a dependency filejavascriptPull requests that update javascript codePull requests that update javascript code
Type
Fields
No fields configured for Bug.
Describe the Bug
MCT recently adopted the CMSDS Pagination component. It contains overridable translations for Previous and Next links, but the mobile-viewport-width content
Page {X} of {XX}is not controlled by a prop, and only uses the CMSDS internal translation helper,t.MCT uses both the
setLanguagehelper from CMSDS and also updates thehtmlelement'slangattribute anytime a user changes language using the switch in the MAX global header. But the component is not updating its content to reflect the language set using the helper or derived from thehtmllangattribute.See code here and observe the value of the
htmllangattribute when switching from English to Spanish and back.To reproduce
Page 1 of 3(or similar)Page 1 of 3has not changed to SpanishExpected behavior
Either changing the
htmllangattribute (fromentoesor vice-versa) or calling CMSDS'ssetLanguagehelper with eitherenores, or both, should update CMSDS components' internal translations.Severity/Impact
High: Affects PI objectives, breaks 508 compliance, breaks application
Desktop Operating System
Mac OS
Desktop Browser Name
Chrome
Desktop Browser Version
149.0.7827.54
Device
N/A
Mobile Operating System
N/A
Mobile Browser Name
N/A
Mobile Browser Version
N/A
Additional context
I have tried all variations of using
htmllangor the CMSDS language helpers (one, not the other, both, choosing to update the URL with alangquery parameter or not -- we do), and no combination of changes trigger the Pagination component to update its internally translated content.Codebase/Repository URL
https://github.com/CMSgov/oc-mct-frontend
Design System Version
Medicare 14.4.5
Existing branch or Pull request on Github
N/A
Team Name
MCT