@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.
45 lines (44 loc) • 1.63 kB
TypeScript
import type { VNType } from "./vn-type.js";
/** A case-scope. */
export type CaseScope = "CCN" | "CCA" | "CCS" | "CCQ" | "CCP" | "CCV";
/** An array containing all case-scopes. */
export declare const ALL_CASE_SCOPES: readonly CaseScope[];
/** An object mapping case-scopes to their Ithkuilic counterparts. */
export declare const CASE_SCOPE_TO_ITHKUIL_MAP: {
readonly false: {
readonly CCN: "h";
readonly CCA: "hl";
readonly CCS: "hr";
readonly CCQ: "hm";
readonly CCP: "hn";
readonly CCV: "hň";
};
readonly true: {
readonly CCN: "w";
readonly CCA: "hw";
readonly CCS: "hrw";
readonly CCQ: "hmw";
readonly CCP: "hnw";
readonly CCV: "hňw";
};
};
/** An object mapping case-scopes to their names. */
export declare const CASE_SCOPE_TO_NAME_MAP: {
readonly CCN: "Natural";
readonly CCA: "Antecedent";
readonly CCS: "Subaltern";
readonly CCQ: "Qualifier";
readonly CCP: "Precedent";
readonly CCV: "Successive";
};
/**
* Converts a case-scope into Ithkuil.
*
* @param caseScope The case-scope to be converted.
* @param vnType The type of Vn form associated with this case-scope. Use
* "aspect" when Vn contains an aspect, "non-aspect" when it contains a
* non-aspect, and "empty" when it has been elided due to the use of MNO
* valence.
* @returns Romanized Ithkuilic text representing the case-scope.
*/
export declare function caseScopeToIthkuil(caseScope: CaseScope, vnType: VNType): "w" | "" | "h" | "hw" | "hl" | "hr" | "hm" | "hn" | "hň" | "hrw" | "hmw" | "hnw" | "hňw";