mirror of
https://github.com/movie-web/native-app.git
synced 2025-09-13 14:03:26 +00:00
added languages with urlsearchparams polyfill that is broken
This commit is contained in:
@@ -1,3 +1,5 @@
|
||||
import iso from "iso-639-1";
|
||||
|
||||
export const mapMillisecondsToTime = (milliseconds: number): string => {
|
||||
const hours = Math.floor(milliseconds / (1000 * 60 * 60));
|
||||
const minutes = Math.floor((milliseconds % (1000 * 60 * 60)) / (1000 * 60));
|
||||
@@ -16,3 +18,8 @@ export const mapMillisecondsToTime = (milliseconds: number): string => {
|
||||
|
||||
return formattedTime;
|
||||
};
|
||||
|
||||
export function getPrettyLanguageNameFromLocale(locale: string): string | null {
|
||||
const language = iso.getName(locale);
|
||||
return language;
|
||||
}
|
||||
|
Reference in New Issue
Block a user