Skip to content
This repository has been archived by the owner on May 24, 2024. It is now read-only.

Commit

Permalink
Locale fix for ie (#339)
Browse files Browse the repository at this point in the history
  • Loading branch information
adoroshk authored Nov 9, 2023
1 parent eddfacd commit f60c663
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 3 deletions.
1 change: 1 addition & 0 deletions packages/terra-application/CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
## Unreleased

* Changed
* Updated `getBrowserLocale` method for IE.
* Updated jest snapshots for terra-icon and terra-button changes.
* Updated size explanations for ModalManager managed by DisclosureManagerContext.
* Locked `uuid` dependency to `3.4.0`.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,10 @@ const getBrowserLocale = () => {
if (preferredLocale) {
return preferredLocale;
}
/* for IE support, as languages and language in IE return undefined, and userLanguage and browserLanguage return "en-US" */
if (isSupported(navigator.systemLanguage)) {
return navigator.systemLanguage;
}

if (isSupported(navigator.language)) {
return navigator.language;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -867,7 +867,7 @@ exports[`UtilityMenu should render with function callbacks 1`] = `
type="button"
>
<span
className="button-label text-only"
className="button-label-win text-only"
>
<span
className=""
Expand Down Expand Up @@ -1163,7 +1163,7 @@ exports[`UtilityMenu should render with function callbacks 1`] = `
type="button"
>
<span
className="button-label text-only"
className="button-label-win text-only"
>
<span
className=""
Expand Down Expand Up @@ -1529,7 +1529,7 @@ exports[`UtilityMenu should render with skip callback 1`] = `
type="button"
>
<span
className="button-label text-only"
className="button-label-win text-only"
>
<span
className=""
Expand Down

0 comments on commit f60c663

Please sign in to comment.