diff --git a/src/js/lib/Quran.ts b/src/js/lib/Quran.ts index 9c7ecd26d..db57684ca 100644 --- a/src/js/lib/Quran.ts +++ b/src/js/lib/Quran.ts @@ -1,8 +1,8 @@ -import * as JSON from "lib/Quran/JSON"; -import { Surah } from "lib/Quran/Surah"; +import * as JSON from 'lib/Quran/JSON'; +import { Surah } from 'lib/Quran/Surah'; type Locale = 'ar' | 'en'; -type Ayah = {id: number, text: string, readTimeMs: number }; +interface Ayah {id: number, text: string, readTimeMs: number } type Ayat = Ayah[]; export { Surah, Ayah, Ayat, Locale, JSON }; diff --git a/src/js/lib/Quran/JSON.ts b/src/js/lib/Quran/JSON.ts index 48b30c93c..7aa3c40ec 100644 --- a/src/js/lib/Quran/JSON.ts +++ b/src/js/lib/Quran/JSON.ts @@ -1,4 +1,4 @@ -type Surah = { +interface Surah { id: string place_of_revelation: string transliterated_name: string diff --git a/src/js/lib/i18n.ts b/src/js/lib/i18n.ts index a0b7928b2..20a8fd019 100644 --- a/src/js/lib/i18n.ts +++ b/src/js/lib/i18n.ts @@ -33,7 +33,7 @@ export const DelayPerWord: Record = { export function numbers (locale: Locale) { return function(number: number): string { - return Number(number).toLocaleString(locale) + return Number(number).toLocaleString(locale); }; } @@ -45,7 +45,7 @@ export function strings (locale: Locale) { } export function numberToDecimal(number: number, locale: Locale): string { - return number.toLocaleString(locale, {maximumFractionDigits: 1}) + return number.toLocaleString(locale, { maximumFractionDigits: 1 }) .split(/([^\d])/) - .join(" ") + .join(' '); }