//#region src/locales/customLocaleMapping.d.ts type CustomMapping = Record>; //#endregion //#region src/locales/getLocaleProperties.d.ts type LocaleProperties = { code: string; name: string; nativeName: string; languageCode: string; languageName: string; nativeLanguageName: string; nameWithRegionCode: string; nativeNameWithRegionCode: string; regionCode: string; regionName: string; nativeRegionName: string; scriptCode: string; scriptName: string; nativeScriptName: string; maximizedCode: string; maximizedName: string; nativeMaximizedName: string; minimizedCode: string; minimizedName: string; nativeMinimizedName: string; emoji: string; }; //#endregion //#region src/locales/getRegionProperties.d.ts type CustomRegionMapping = { [region: string]: { name?: string; emoji?: string; locale?: string; }; }; /** * Retrieves multiple properties for a given region code, including: * - `code`: the original region code * - `name`: the localized display name * - `emoji`: the associated flag or symbol * * Behavior: * - Accepts ISO 3166-1 alpha-2 or UN M.49 region codes (e.g., `"US"`, `"FR"`, `"419"`). * - If `customMapping` contains a `name` or `emoji` for the region, those override the default values. * - Otherwise, uses `Intl.DisplayNames` to get the localized region name in the given `defaultLocale`, * falling back to `libraryDefaultLocale`. * - Falls back to the region code as `name` if display name resolution fails. * - Falls back to `defaultEmoji` if no emoji can be computed or found in `customMapping`. * * @param {string} region - The region code to look up (e.g., `"US"`, `"GB"`, `"DE"`). * @param {string} [defaultLocale=libraryDefaultLocale] - The locale to use when localizing the region name. * @param {CustomRegionMapping} [customMapping] - Optional mapping of region codes to custom names and/or emojis. * @returns {{ code: string, name: string, emoji: string, locale?: string }} An object containing: * - `code`: the input region code * - `name`: the localized or custom region name * - `emoji`: the matching emoji flag or symbol * - `locale`: the optional associated locale from custom mapping * * @example * getRegionProperties('US', 'en'); * // => { code: 'US', name: 'United States', emoji: '๐Ÿ‡บ๐Ÿ‡ธ' } * * @example * getRegionProperties('US', 'fr'); * // => { code: 'US', name: 'ร‰tats-Unis', emoji: '๐Ÿ‡บ๐Ÿ‡ธ' } * * @example * getRegionProperties('US', 'en', { US: { name: 'USA', emoji: '๐Ÿ—ฝ' } }); * // => { code: 'US', name: 'USA', emoji: '๐Ÿ—ฝ' } */ declare function getRegionProperties(region: string, defaultLocale?: string, customMapping?: CustomRegionMapping): { code: string; name: string; emoji: string; locale?: string; }; //#endregion //#region src/formatting/custom-formats/CutoffFormat/types.d.ts /** Type of terminator */ type CutoffFormatStyle = 'none' | 'ellipsis'; /** Terminator options. */ interface TerminatorOptions { /** The terminator to use. */ terminator?: string; /** An optional separator between the terminator and the value */ separator?: string; } /** Input formatting options (for constructor) */ interface CutoffFormatOptions extends TerminatorOptions { /** Cutoff length. */ maxChars?: number; /** Type of terminator */ style?: CutoffFormatStyle; } //#endregion //#region src/types-dir/jsx/variables.d.ts type VariableType = 'v' | 'n' | 'd' | 'c' | 'rt'; /** * Variables are used to store the variable name and type. */ type Variable = { k: string; i?: number; v?: VariableType; }; //#endregion //#region src/types-dir/jsx/content.d.ts /** * Map of data-_gt properties to their corresponding React props */ declare const HTML_CONTENT_PROPS: { readonly pl: "placeholder"; readonly ti: "title"; readonly alt: "alt"; readonly arl: "aria-label"; readonly arb: "aria-labelledby"; readonly ard: "aria-describedby"; }; type HtmlContentPropKeysRecord = Partial>; type HtmlContentPropValuesRecord = Partial>; /** * GTProp is an internal property used to contain data for translating and rendering elements. * note, transformations are only read on the server side if they are 'plural' or 'branch' */ type GTProp = { b?: Record; t?: 'p' | 'b'; } & HtmlContentPropKeysRecord; type JsxElement = { t?: string; i?: number; d?: GTProp; c?: JsxChildren; }; type JsxChild = string | JsxElement | Variable; /** * The format of the string content */ type StringFormat = 'ICU' | 'I18NEXT' | 'STRING'; /** * The format of the content. */ type DataFormat = 'JSX' | StringFormat; /** * String format content. */ type StringContent = IcuMessage | StringMessage | I18nextMessage; /** * A content type representing JSX, ICU, and I18next messages. */ type Content = JsxChildren | StringContent; /** * GT's persisted rich-content wire format. * * React preserves scalar boolean and null children, including nested element * content and Branch or Plural alternatives. Arrays omit those empty-rendering * primitives through React's child normalization. */ type JsxChildren = boolean | null | JsxChild | JsxChild[]; /** * A content type representing ICU messages. */ type IcuMessage = string; /** * A content type representing I18next messages. */ type I18nextMessage = string; /** * A content type representing plain strings. */ type StringMessage = string; //#endregion //#region src/types.d.ts type FormatVariables = Record; //#endregion export { CustomMapping as S, VariableType as _, HTML_CONTENT_PROPS as a, getRegionProperties as b, I18nextMessage as c, JsxChildren as d, JsxElement as f, Variable as g, StringMessage as h, GTProp as i, IcuMessage as l, StringFormat as m, Content as n, HtmlContentPropKeysRecord as o, StringContent as p, DataFormat as r, HtmlContentPropValuesRecord as s, FormatVariables as t, JsxChild as u, CutoffFormatOptions as v, LocaleProperties as x, CustomRegionMapping as y }; //# sourceMappingURL=types-CbRDetV3.d.cts.map