@zsnout/ithkuil
Version:
A set of tools which can generate and parse romanized Ithkuil text and which can generate Ithkuil script from text and JSON data.
55 lines (54 loc) • 2.2 kB
TypeScript
/** A global regular expression matching Ithkuilic consonants. */
export declare const CONSONANT: RegExp;
/**
* Extracts the vowels from a given text.
*
* @param text The text to extract vowels from.
* @returns The vowels of the given text.
*/
export declare function extractAllVowels(text: string): string;
/** A global regular expression matching Ithkuilic vowels. */
export declare const VOWEL: RegExp;
/**
* Extracts the consonants from a given text.
*
* @param text The text to extract consonants from.
* @returns The consonants of the given text.
*/
export declare function extractAllConsonants(text: string): string;
/** A regular expression matching an initial consonant cluster. */
export declare const INITIAL_CONSONANT_CLUSTER: RegExp;
/**
* Extracts the initial consonant cluster of a word.
*
* @param text The text to extract a cluster from.
* @returns The matched cluster, or `undefined` is no such cluster exists.
*/
export declare function extractInitialConsonantCluster(text: string): string | undefined;
/** A regular expression matching a final consonant cluster. */
export declare const FINAL_CONSONANT_CLUSTER: RegExp;
/**
* Extracts the final consonant cluster of a word.
*
* @param text The text to extract a cluster from.
* @returns The matched cluster, or `undefined` is no such cluster exists.
*/
export declare function extractFinalConsonantCluster(text: string): string | undefined;
/** A regular expression matching an initial vowel cluster. */
export declare const INITIAL_VOWEL_CLUSTER: RegExp;
/**
* Extracts the initial vowel cluster of a word.
*
* @param text The text to extract a cluster from.
* @returns The matched cluster, or `undefined` is no such cluster exists.
*/
export declare function extractInitialVowelCluster(text: string): string | undefined;
/** A regular expression matching a final vowel cluster. */
export declare const FINAL_VOWEL_CLUSTER: RegExp;
/**
* Extracts the final vowel cluster of a word.
*
* @param text The text to extract a cluster from.
* @returns The matched cluster, or `undefined` is no such cluster exists.
*/
export declare function extractFinalVowelCluster(text: string): string | undefined;