import { Country } from './country'; import { CountryInterface, FilterOption, GroupedCountries } from './types'; declare class App { phoneNumberUtil: any; /** * find one by ISO 3166-1 alpha-2 eg. US, MM * * @param {string} code * @returns {Country | undefined} */ findOneByCountryCode(code: string): Country | undefined; /** * find one by phone dial code eg. +1, +95 * * @param {string} dialCode * @returns {Country | undefined} */ findOneByDialCode(dialCode: string): Country | undefined; /** * Find list of countries by country code code * * @param {string} code * @returns {Array} */ findByCountryCode(code: string, option?: FilterOption): Array; /** * Find list of countries by phone dial code eg. +1, +95 * * @param {string} dialCode * @returns {Array} */ findByDialCode(dialCode: string): Array; /** * Find list of countries by keyword, eg. United, Myanmar, India * * @param {string} keyword * @returns {Array} */ findByKeyword(keyword: string, option?: FilterOption): Array; /** * Find list of countries by currency code, eg. USD, TRY, EUR * * @param {string} code * @returns {Array} */ findByCurrencyCode(code: string, option?: FilterOption): Array; /** * find one by currency code, eg. USD, TRY, EUR * * @param {string} currencyCode * @returns {Country | undefined} */ findOneByCurrencyCode(currencyCode: string): Country | undefined; /** * get all countries * * @returns {Array} */ getAll(option?: FilterOption): Array; /** * Group countries by the first letter of their name * @param array * @returns {GroupedCountries} */ groupCountriesByFirstLetter(array?: Country[] | CountryInterface[]): GroupedCountries; /** * set phone number util to use phone number formatter * @param phoneNumberUtil */ setPhoneNumberUtil(phoneNumberUtil: any): void; } declare const CountryList: App; declare global { interface Window { CountryList: App; } } export default CountryList; export { Country, FilterOption };