UNPKG

@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.

181 lines (180 loc) 25 kB
import { type Affix, type AffixDegree, type AffixType, type PartialFormative } from "../../generate/index.js"; import { type AdvancedAlphabeticCharacter, type BiasCharacter, type PrimaryCharacter, type RegisterCharacter, type RowProps, type SecondaryCharacter, type TertiaryCharacter } from "../index.js"; import type { NumeralCharacter } from "../numerals/index.js"; import type { BreakCharacter } from "../other/break.js"; import { type QuaternaryCharacter } from "../quaternary/index.js"; /** Information about a generic character. */ export type Character = PrimaryCharacter | SecondaryCharacter | TertiaryCharacter | QuaternaryCharacter | BiasCharacter | RegisterCharacter | NumeralCharacter | BreakCharacter | AdvancedAlphabeticCharacter; /** A script character paired with its constructor. */ export type ConstructableCharacter<T extends Character = Character> = T & { construct(character: T): SVGGElement; readonly dimmed?: boolean | undefined; readonly handwritten?: boolean | undefined; }; /** An object mapping affix degrees to their corresponding diacritics. */ export declare const AFFIX_DEGREES: { readonly [x: number]: "DOT" | "HORIZ_BAR" | "DIAG_BAR" | "HORIZ_WITH_TOP_LINE" | "HORIZ_WITH_BOTTOM_LINE" | "VERT_WITH_LEFT_LINE" | "VERT_WITH_RIGHT_LINE" | "CURVE_TO_RIGHT" | "CURVE_TO_TOP" | "CURVE_TO_BOTTOM"; readonly 0: "CURVE_TO_RIGHT"; readonly 1: "DOT"; readonly 2: "HORIZ_WITH_BOTTOM_LINE"; readonly 3: "VERT_WITH_RIGHT_LINE"; readonly 4: "CURVE_TO_TOP"; readonly 5: "DIAG_BAR"; readonly 6: "CURVE_TO_BOTTOM"; readonly 7: "VERT_WITH_LEFT_LINE"; readonly 8: "HORIZ_WITH_TOP_LINE"; readonly 9: "HORIZ_BAR"; readonly length: 10; readonly toString: () => string; readonly toLocaleString: { (): string; (locales: string | string[], options?: Intl.NumberFormatOptions & Intl.DateTimeFormatOptions): string; }; readonly concat: { (...items: ConcatArray<"DOT" | "HORIZ_BAR" | "DIAG_BAR" | "HORIZ_WITH_TOP_LINE" | "HORIZ_WITH_BOTTOM_LINE" | "VERT_WITH_LEFT_LINE" | "VERT_WITH_RIGHT_LINE" | "CURVE_TO_RIGHT" | "CURVE_TO_TOP" | "CURVE_TO_BOTTOM">[]): ("DOT" | "HORIZ_BAR" | "DIAG_BAR" | "HORIZ_WITH_TOP_LINE" | "HORIZ_WITH_BOTTOM_LINE" | "VERT_WITH_LEFT_LINE" | "VERT_WITH_RIGHT_LINE" | "CURVE_TO_RIGHT" | "CURVE_TO_TOP" | "CURVE_TO_BOTTOM")[]; (...items: ("DOT" | "HORIZ_BAR" | "DIAG_BAR" | "HORIZ_WITH_TOP_LINE" | "HORIZ_WITH_BOTTOM_LINE" | "VERT_WITH_LEFT_LINE" | "VERT_WITH_RIGHT_LINE" | "CURVE_TO_RIGHT" | "CURVE_TO_TOP" | "CURVE_TO_BOTTOM" | ConcatArray<"DOT" | "HORIZ_BAR" | "DIAG_BAR" | "HORIZ_WITH_TOP_LINE" | "HORIZ_WITH_BOTTOM_LINE" | "VERT_WITH_LEFT_LINE" | "VERT_WITH_RIGHT_LINE" | "CURVE_TO_RIGHT" | "CURVE_TO_TOP" | "CURVE_TO_BOTTOM">)[]): ("DOT" | "HORIZ_BAR" | "DIAG_BAR" | "HORIZ_WITH_TOP_LINE" | "HORIZ_WITH_BOTTOM_LINE" | "VERT_WITH_LEFT_LINE" | "VERT_WITH_RIGHT_LINE" | "CURVE_TO_RIGHT" | "CURVE_TO_TOP" | "CURVE_TO_BOTTOM")[]; }; readonly join: (separator?: string) => string; readonly slice: (start?: number, end?: number) => ("DOT" | "HORIZ_BAR" | "DIAG_BAR" | "HORIZ_WITH_TOP_LINE" | "HORIZ_WITH_BOTTOM_LINE" | "VERT_WITH_LEFT_LINE" | "VERT_WITH_RIGHT_LINE" | "CURVE_TO_RIGHT" | "CURVE_TO_TOP" | "CURVE_TO_BOTTOM")[]; readonly indexOf: (searchElement: "DOT" | "HORIZ_BAR" | "DIAG_BAR" | "HORIZ_WITH_TOP_LINE" | "HORIZ_WITH_BOTTOM_LINE" | "VERT_WITH_LEFT_LINE" | "VERT_WITH_RIGHT_LINE" | "CURVE_TO_RIGHT" | "CURVE_TO_TOP" | "CURVE_TO_BOTTOM", fromIndex?: number) => number; readonly lastIndexOf: (searchElement: "DOT" | "HORIZ_BAR" | "DIAG_BAR" | "HORIZ_WITH_TOP_LINE" | "HORIZ_WITH_BOTTOM_LINE" | "VERT_WITH_LEFT_LINE" | "VERT_WITH_RIGHT_LINE" | "CURVE_TO_RIGHT" | "CURVE_TO_TOP" | "CURVE_TO_BOTTOM", fromIndex?: number) => number; readonly every: { <S extends "DOT" | "HORIZ_BAR" | "DIAG_BAR" | "HORIZ_WITH_TOP_LINE" | "HORIZ_WITH_BOTTOM_LINE" | "VERT_WITH_LEFT_LINE" | "VERT_WITH_RIGHT_LINE" | "CURVE_TO_RIGHT" | "CURVE_TO_TOP" | "CURVE_TO_BOTTOM">(predicate: (value: "DOT" | "HORIZ_BAR" | "DIAG_BAR" | "HORIZ_WITH_TOP_LINE" | "HORIZ_WITH_BOTTOM_LINE" | "VERT_WITH_LEFT_LINE" | "VERT_WITH_RIGHT_LINE" | "CURVE_TO_RIGHT" | "CURVE_TO_TOP" | "CURVE_TO_BOTTOM", index: number, array: readonly ("DOT" | "HORIZ_BAR" | "DIAG_BAR" | "HORIZ_WITH_TOP_LINE" | "HORIZ_WITH_BOTTOM_LINE" | "VERT_WITH_LEFT_LINE" | "VERT_WITH_RIGHT_LINE" | "CURVE_TO_RIGHT" | "CURVE_TO_TOP" | "CURVE_TO_BOTTOM")[]) => value is S, thisArg?: any): this is readonly S[]; (predicate: (value: "DOT" | "HORIZ_BAR" | "DIAG_BAR" | "HORIZ_WITH_TOP_LINE" | "HORIZ_WITH_BOTTOM_LINE" | "VERT_WITH_LEFT_LINE" | "VERT_WITH_RIGHT_LINE" | "CURVE_TO_RIGHT" | "CURVE_TO_TOP" | "CURVE_TO_BOTTOM", index: number, array: readonly ("DOT" | "HORIZ_BAR" | "DIAG_BAR" | "HORIZ_WITH_TOP_LINE" | "HORIZ_WITH_BOTTOM_LINE" | "VERT_WITH_LEFT_LINE" | "VERT_WITH_RIGHT_LINE" | "CURVE_TO_RIGHT" | "CURVE_TO_TOP" | "CURVE_TO_BOTTOM")[]) => unknown, thisArg?: any): boolean; }; readonly some: (predicate: (value: "DOT" | "HORIZ_BAR" | "DIAG_BAR" | "HORIZ_WITH_TOP_LINE" | "HORIZ_WITH_BOTTOM_LINE" | "VERT_WITH_LEFT_LINE" | "VERT_WITH_RIGHT_LINE" | "CURVE_TO_RIGHT" | "CURVE_TO_TOP" | "CURVE_TO_BOTTOM", index: number, array: readonly ("DOT" | "HORIZ_BAR" | "DIAG_BAR" | "HORIZ_WITH_TOP_LINE" | "HORIZ_WITH_BOTTOM_LINE" | "VERT_WITH_LEFT_LINE" | "VERT_WITH_RIGHT_LINE" | "CURVE_TO_RIGHT" | "CURVE_TO_TOP" | "CURVE_TO_BOTTOM")[]) => unknown, thisArg?: any) => boolean; readonly forEach: (callbackfn: (value: "DOT" | "HORIZ_BAR" | "DIAG_BAR" | "HORIZ_WITH_TOP_LINE" | "HORIZ_WITH_BOTTOM_LINE" | "VERT_WITH_LEFT_LINE" | "VERT_WITH_RIGHT_LINE" | "CURVE_TO_RIGHT" | "CURVE_TO_TOP" | "CURVE_TO_BOTTOM", index: number, array: readonly ("DOT" | "HORIZ_BAR" | "DIAG_BAR" | "HORIZ_WITH_TOP_LINE" | "HORIZ_WITH_BOTTOM_LINE" | "VERT_WITH_LEFT_LINE" | "VERT_WITH_RIGHT_LINE" | "CURVE_TO_RIGHT" | "CURVE_TO_TOP" | "CURVE_TO_BOTTOM")[]) => void, thisArg?: any) => void; readonly map: <U>(callbackfn: (value: "DOT" | "HORIZ_BAR" | "DIAG_BAR" | "HORIZ_WITH_TOP_LINE" | "HORIZ_WITH_BOTTOM_LINE" | "VERT_WITH_LEFT_LINE" | "VERT_WITH_RIGHT_LINE" | "CURVE_TO_RIGHT" | "CURVE_TO_TOP" | "CURVE_TO_BOTTOM", index: number, array: readonly ("DOT" | "HORIZ_BAR" | "DIAG_BAR" | "HORIZ_WITH_TOP_LINE" | "HORIZ_WITH_BOTTOM_LINE" | "VERT_WITH_LEFT_LINE" | "VERT_WITH_RIGHT_LINE" | "CURVE_TO_RIGHT" | "CURVE_TO_TOP" | "CURVE_TO_BOTTOM")[]) => U, thisArg?: any) => U[]; readonly filter: { <S extends "DOT" | "HORIZ_BAR" | "DIAG_BAR" | "HORIZ_WITH_TOP_LINE" | "HORIZ_WITH_BOTTOM_LINE" | "VERT_WITH_LEFT_LINE" | "VERT_WITH_RIGHT_LINE" | "CURVE_TO_RIGHT" | "CURVE_TO_TOP" | "CURVE_TO_BOTTOM">(predicate: (value: "DOT" | "HORIZ_BAR" | "DIAG_BAR" | "HORIZ_WITH_TOP_LINE" | "HORIZ_WITH_BOTTOM_LINE" | "VERT_WITH_LEFT_LINE" | "VERT_WITH_RIGHT_LINE" | "CURVE_TO_RIGHT" | "CURVE_TO_TOP" | "CURVE_TO_BOTTOM", index: number, array: readonly ("DOT" | "HORIZ_BAR" | "DIAG_BAR" | "HORIZ_WITH_TOP_LINE" | "HORIZ_WITH_BOTTOM_LINE" | "VERT_WITH_LEFT_LINE" | "VERT_WITH_RIGHT_LINE" | "CURVE_TO_RIGHT" | "CURVE_TO_TOP" | "CURVE_TO_BOTTOM")[]) => value is S, thisArg?: any): S[]; (predicate: (value: "DOT" | "HORIZ_BAR" | "DIAG_BAR" | "HORIZ_WITH_TOP_LINE" | "HORIZ_WITH_BOTTOM_LINE" | "VERT_WITH_LEFT_LINE" | "VERT_WITH_RIGHT_LINE" | "CURVE_TO_RIGHT" | "CURVE_TO_TOP" | "CURVE_TO_BOTTOM", index: number, array: readonly ("DOT" | "HORIZ_BAR" | "DIAG_BAR" | "HORIZ_WITH_TOP_LINE" | "HORIZ_WITH_BOTTOM_LINE" | "VERT_WITH_LEFT_LINE" | "VERT_WITH_RIGHT_LINE" | "CURVE_TO_RIGHT" | "CURVE_TO_TOP" | "CURVE_TO_BOTTOM")[]) => unknown, thisArg?: any): ("DOT" | "HORIZ_BAR" | "DIAG_BAR" | "HORIZ_WITH_TOP_LINE" | "HORIZ_WITH_BOTTOM_LINE" | "VERT_WITH_LEFT_LINE" | "VERT_WITH_RIGHT_LINE" | "CURVE_TO_RIGHT" | "CURVE_TO_TOP" | "CURVE_TO_BOTTOM")[]; }; readonly reduce: { (callbackfn: (previousValue: "DOT" | "HORIZ_BAR" | "DIAG_BAR" | "HORIZ_WITH_TOP_LINE" | "HORIZ_WITH_BOTTOM_LINE" | "VERT_WITH_LEFT_LINE" | "VERT_WITH_RIGHT_LINE" | "CURVE_TO_RIGHT" | "CURVE_TO_TOP" | "CURVE_TO_BOTTOM", currentValue: "DOT" | "HORIZ_BAR" | "DIAG_BAR" | "HORIZ_WITH_TOP_LINE" | "HORIZ_WITH_BOTTOM_LINE" | "VERT_WITH_LEFT_LINE" | "VERT_WITH_RIGHT_LINE" | "CURVE_TO_RIGHT" | "CURVE_TO_TOP" | "CURVE_TO_BOTTOM", currentIndex: number, array: readonly ("DOT" | "HORIZ_BAR" | "DIAG_BAR" | "HORIZ_WITH_TOP_LINE" | "HORIZ_WITH_BOTTOM_LINE" | "VERT_WITH_LEFT_LINE" | "VERT_WITH_RIGHT_LINE" | "CURVE_TO_RIGHT" | "CURVE_TO_TOP" | "CURVE_TO_BOTTOM")[]) => "DOT" | "HORIZ_BAR" | "DIAG_BAR" | "HORIZ_WITH_TOP_LINE" | "HORIZ_WITH_BOTTOM_LINE" | "VERT_WITH_LEFT_LINE" | "VERT_WITH_RIGHT_LINE" | "CURVE_TO_RIGHT" | "CURVE_TO_TOP" | "CURVE_TO_BOTTOM"): "DOT" | "HORIZ_BAR" | "DIAG_BAR" | "HORIZ_WITH_TOP_LINE" | "HORIZ_WITH_BOTTOM_LINE" | "VERT_WITH_LEFT_LINE" | "VERT_WITH_RIGHT_LINE" | "CURVE_TO_RIGHT" | "CURVE_TO_TOP" | "CURVE_TO_BOTTOM"; (callbackfn: (previousValue: "DOT" | "HORIZ_BAR" | "DIAG_BAR" | "HORIZ_WITH_TOP_LINE" | "HORIZ_WITH_BOTTOM_LINE" | "VERT_WITH_LEFT_LINE" | "VERT_WITH_RIGHT_LINE" | "CURVE_TO_RIGHT" | "CURVE_TO_TOP" | "CURVE_TO_BOTTOM", currentValue: "DOT" | "HORIZ_BAR" | "DIAG_BAR" | "HORIZ_WITH_TOP_LINE" | "HORIZ_WITH_BOTTOM_LINE" | "VERT_WITH_LEFT_LINE" | "VERT_WITH_RIGHT_LINE" | "CURVE_TO_RIGHT" | "CURVE_TO_TOP" | "CURVE_TO_BOTTOM", currentIndex: number, array: readonly ("DOT" | "HORIZ_BAR" | "DIAG_BAR" | "HORIZ_WITH_TOP_LINE" | "HORIZ_WITH_BOTTOM_LINE" | "VERT_WITH_LEFT_LINE" | "VERT_WITH_RIGHT_LINE" | "CURVE_TO_RIGHT" | "CURVE_TO_TOP" | "CURVE_TO_BOTTOM")[]) => "DOT" | "HORIZ_BAR" | "DIAG_BAR" | "HORIZ_WITH_TOP_LINE" | "HORIZ_WITH_BOTTOM_LINE" | "VERT_WITH_LEFT_LINE" | "VERT_WITH_RIGHT_LINE" | "CURVE_TO_RIGHT" | "CURVE_TO_TOP" | "CURVE_TO_BOTTOM", initialValue: "DOT" | "HORIZ_BAR" | "DIAG_BAR" | "HORIZ_WITH_TOP_LINE" | "HORIZ_WITH_BOTTOM_LINE" | "VERT_WITH_LEFT_LINE" | "VERT_WITH_RIGHT_LINE" | "CURVE_TO_RIGHT" | "CURVE_TO_TOP" | "CURVE_TO_BOTTOM"): "DOT" | "HORIZ_BAR" | "DIAG_BAR" | "HORIZ_WITH_TOP_LINE" | "HORIZ_WITH_BOTTOM_LINE" | "VERT_WITH_LEFT_LINE" | "VERT_WITH_RIGHT_LINE" | "CURVE_TO_RIGHT" | "CURVE_TO_TOP" | "CURVE_TO_BOTTOM"; <U>(callbackfn: (previousValue: U, currentValue: "DOT" | "HORIZ_BAR" | "DIAG_BAR" | "HORIZ_WITH_TOP_LINE" | "HORIZ_WITH_BOTTOM_LINE" | "VERT_WITH_LEFT_LINE" | "VERT_WITH_RIGHT_LINE" | "CURVE_TO_RIGHT" | "CURVE_TO_TOP" | "CURVE_TO_BOTTOM", currentIndex: number, array: readonly ("DOT" | "HORIZ_BAR" | "DIAG_BAR" | "HORIZ_WITH_TOP_LINE" | "HORIZ_WITH_BOTTOM_LINE" | "VERT_WITH_LEFT_LINE" | "VERT_WITH_RIGHT_LINE" | "CURVE_TO_RIGHT" | "CURVE_TO_TOP" | "CURVE_TO_BOTTOM")[]) => U, initialValue: U): U; }; readonly reduceRight: { (callbackfn: (previousValue: "DOT" | "HORIZ_BAR" | "DIAG_BAR" | "HORIZ_WITH_TOP_LINE" | "HORIZ_WITH_BOTTOM_LINE" | "VERT_WITH_LEFT_LINE" | "VERT_WITH_RIGHT_LINE" | "CURVE_TO_RIGHT" | "CURVE_TO_TOP" | "CURVE_TO_BOTTOM", currentValue: "DOT" | "HORIZ_BAR" | "DIAG_BAR" | "HORIZ_WITH_TOP_LINE" | "HORIZ_WITH_BOTTOM_LINE" | "VERT_WITH_LEFT_LINE" | "VERT_WITH_RIGHT_LINE" | "CURVE_TO_RIGHT" | "CURVE_TO_TOP" | "CURVE_TO_BOTTOM", currentIndex: number, array: readonly ("DOT" | "HORIZ_BAR" | "DIAG_BAR" | "HORIZ_WITH_TOP_LINE" | "HORIZ_WITH_BOTTOM_LINE" | "VERT_WITH_LEFT_LINE" | "VERT_WITH_RIGHT_LINE" | "CURVE_TO_RIGHT" | "CURVE_TO_TOP" | "CURVE_TO_BOTTOM")[]) => "DOT" | "HORIZ_BAR" | "DIAG_BAR" | "HORIZ_WITH_TOP_LINE" | "HORIZ_WITH_BOTTOM_LINE" | "VERT_WITH_LEFT_LINE" | "VERT_WITH_RIGHT_LINE" | "CURVE_TO_RIGHT" | "CURVE_TO_TOP" | "CURVE_TO_BOTTOM"): "DOT" | "HORIZ_BAR" | "DIAG_BAR" | "HORIZ_WITH_TOP_LINE" | "HORIZ_WITH_BOTTOM_LINE" | "VERT_WITH_LEFT_LINE" | "VERT_WITH_RIGHT_LINE" | "CURVE_TO_RIGHT" | "CURVE_TO_TOP" | "CURVE_TO_BOTTOM"; (callbackfn: (previousValue: "DOT" | "HORIZ_BAR" | "DIAG_BAR" | "HORIZ_WITH_TOP_LINE" | "HORIZ_WITH_BOTTOM_LINE" | "VERT_WITH_LEFT_LINE" | "VERT_WITH_RIGHT_LINE" | "CURVE_TO_RIGHT" | "CURVE_TO_TOP" | "CURVE_TO_BOTTOM", currentValue: "DOT" | "HORIZ_BAR" | "DIAG_BAR" | "HORIZ_WITH_TOP_LINE" | "HORIZ_WITH_BOTTOM_LINE" | "VERT_WITH_LEFT_LINE" | "VERT_WITH_RIGHT_LINE" | "CURVE_TO_RIGHT" | "CURVE_TO_TOP" | "CURVE_TO_BOTTOM", currentIndex: number, array: readonly ("DOT" | "HORIZ_BAR" | "DIAG_BAR" | "HORIZ_WITH_TOP_LINE" | "HORIZ_WITH_BOTTOM_LINE" | "VERT_WITH_LEFT_LINE" | "VERT_WITH_RIGHT_LINE" | "CURVE_TO_RIGHT" | "CURVE_TO_TOP" | "CURVE_TO_BOTTOM")[]) => "DOT" | "HORIZ_BAR" | "DIAG_BAR" | "HORIZ_WITH_TOP_LINE" | "HORIZ_WITH_BOTTOM_LINE" | "VERT_WITH_LEFT_LINE" | "VERT_WITH_RIGHT_LINE" | "CURVE_TO_RIGHT" | "CURVE_TO_TOP" | "CURVE_TO_BOTTOM", initialValue: "DOT" | "HORIZ_BAR" | "DIAG_BAR" | "HORIZ_WITH_TOP_LINE" | "HORIZ_WITH_BOTTOM_LINE" | "VERT_WITH_LEFT_LINE" | "VERT_WITH_RIGHT_LINE" | "CURVE_TO_RIGHT" | "CURVE_TO_TOP" | "CURVE_TO_BOTTOM"): "DOT" | "HORIZ_BAR" | "DIAG_BAR" | "HORIZ_WITH_TOP_LINE" | "HORIZ_WITH_BOTTOM_LINE" | "VERT_WITH_LEFT_LINE" | "VERT_WITH_RIGHT_LINE" | "CURVE_TO_RIGHT" | "CURVE_TO_TOP" | "CURVE_TO_BOTTOM"; <U>(callbackfn: (previousValue: U, currentValue: "DOT" | "HORIZ_BAR" | "DIAG_BAR" | "HORIZ_WITH_TOP_LINE" | "HORIZ_WITH_BOTTOM_LINE" | "VERT_WITH_LEFT_LINE" | "VERT_WITH_RIGHT_LINE" | "CURVE_TO_RIGHT" | "CURVE_TO_TOP" | "CURVE_TO_BOTTOM", currentIndex: number, array: readonly ("DOT" | "HORIZ_BAR" | "DIAG_BAR" | "HORIZ_WITH_TOP_LINE" | "HORIZ_WITH_BOTTOM_LINE" | "VERT_WITH_LEFT_LINE" | "VERT_WITH_RIGHT_LINE" | "CURVE_TO_RIGHT" | "CURVE_TO_TOP" | "CURVE_TO_BOTTOM")[]) => U, initialValue: U): U; }; readonly find: { <S extends "DOT" | "HORIZ_BAR" | "DIAG_BAR" | "HORIZ_WITH_TOP_LINE" | "HORIZ_WITH_BOTTOM_LINE" | "VERT_WITH_LEFT_LINE" | "VERT_WITH_RIGHT_LINE" | "CURVE_TO_RIGHT" | "CURVE_TO_TOP" | "CURVE_TO_BOTTOM">(predicate: (value: "DOT" | "HORIZ_BAR" | "DIAG_BAR" | "HORIZ_WITH_TOP_LINE" | "HORIZ_WITH_BOTTOM_LINE" | "VERT_WITH_LEFT_LINE" | "VERT_WITH_RIGHT_LINE" | "CURVE_TO_RIGHT" | "CURVE_TO_TOP" | "CURVE_TO_BOTTOM", index: number, obj: readonly ("DOT" | "HORIZ_BAR" | "DIAG_BAR" | "HORIZ_WITH_TOP_LINE" | "HORIZ_WITH_BOTTOM_LINE" | "VERT_WITH_LEFT_LINE" | "VERT_WITH_RIGHT_LINE" | "CURVE_TO_RIGHT" | "CURVE_TO_TOP" | "CURVE_TO_BOTTOM")[]) => value is S, thisArg?: any): S | undefined; (predicate: (value: "DOT" | "HORIZ_BAR" | "DIAG_BAR" | "HORIZ_WITH_TOP_LINE" | "HORIZ_WITH_BOTTOM_LINE" | "VERT_WITH_LEFT_LINE" | "VERT_WITH_RIGHT_LINE" | "CURVE_TO_RIGHT" | "CURVE_TO_TOP" | "CURVE_TO_BOTTOM", index: number, obj: readonly ("DOT" | "HORIZ_BAR" | "DIAG_BAR" | "HORIZ_WITH_TOP_LINE" | "HORIZ_WITH_BOTTOM_LINE" | "VERT_WITH_LEFT_LINE" | "VERT_WITH_RIGHT_LINE" | "CURVE_TO_RIGHT" | "CURVE_TO_TOP" | "CURVE_TO_BOTTOM")[]) => unknown, thisArg?: any): "DOT" | "HORIZ_BAR" | "DIAG_BAR" | "HORIZ_WITH_TOP_LINE" | "HORIZ_WITH_BOTTOM_LINE" | "VERT_WITH_LEFT_LINE" | "VERT_WITH_RIGHT_LINE" | "CURVE_TO_RIGHT" | "CURVE_TO_TOP" | "CURVE_TO_BOTTOM" | undefined; }; readonly findIndex: (predicate: (value: "DOT" | "HORIZ_BAR" | "DIAG_BAR" | "HORIZ_WITH_TOP_LINE" | "HORIZ_WITH_BOTTOM_LINE" | "VERT_WITH_LEFT_LINE" | "VERT_WITH_RIGHT_LINE" | "CURVE_TO_RIGHT" | "CURVE_TO_TOP" | "CURVE_TO_BOTTOM", index: number, obj: readonly ("DOT" | "HORIZ_BAR" | "DIAG_BAR" | "HORIZ_WITH_TOP_LINE" | "HORIZ_WITH_BOTTOM_LINE" | "VERT_WITH_LEFT_LINE" | "VERT_WITH_RIGHT_LINE" | "CURVE_TO_RIGHT" | "CURVE_TO_TOP" | "CURVE_TO_BOTTOM")[]) => unknown, thisArg?: any) => number; readonly entries: () => ArrayIterator<[number, "DOT" | "HORIZ_BAR" | "DIAG_BAR" | "HORIZ_WITH_TOP_LINE" | "HORIZ_WITH_BOTTOM_LINE" | "VERT_WITH_LEFT_LINE" | "VERT_WITH_RIGHT_LINE" | "CURVE_TO_RIGHT" | "CURVE_TO_TOP" | "CURVE_TO_BOTTOM"]>; readonly keys: () => ArrayIterator<number>; readonly values: () => ArrayIterator<"DOT" | "HORIZ_BAR" | "DIAG_BAR" | "HORIZ_WITH_TOP_LINE" | "HORIZ_WITH_BOTTOM_LINE" | "VERT_WITH_LEFT_LINE" | "VERT_WITH_RIGHT_LINE" | "CURVE_TO_RIGHT" | "CURVE_TO_TOP" | "CURVE_TO_BOTTOM">; readonly includes: (searchElement: "DOT" | "HORIZ_BAR" | "DIAG_BAR" | "HORIZ_WITH_TOP_LINE" | "HORIZ_WITH_BOTTOM_LINE" | "VERT_WITH_LEFT_LINE" | "VERT_WITH_RIGHT_LINE" | "CURVE_TO_RIGHT" | "CURVE_TO_TOP" | "CURVE_TO_BOTTOM", fromIndex?: number) => boolean; readonly flatMap: <U, This = undefined>(callback: (this: This, value: "DOT" | "HORIZ_BAR" | "DIAG_BAR" | "HORIZ_WITH_TOP_LINE" | "HORIZ_WITH_BOTTOM_LINE" | "VERT_WITH_LEFT_LINE" | "VERT_WITH_RIGHT_LINE" | "CURVE_TO_RIGHT" | "CURVE_TO_TOP" | "CURVE_TO_BOTTOM", index: number, array: ("DOT" | "HORIZ_BAR" | "DIAG_BAR" | "HORIZ_WITH_TOP_LINE" | "HORIZ_WITH_BOTTOM_LINE" | "VERT_WITH_LEFT_LINE" | "VERT_WITH_RIGHT_LINE" | "CURVE_TO_RIGHT" | "CURVE_TO_TOP" | "CURVE_TO_BOTTOM")[]) => U | readonly U[], thisArg?: This | undefined) => U[]; readonly flat: <A, D extends number = 1>(this: A, depth?: D | undefined) => FlatArray<A, D>[]; readonly at: (index: number) => "DOT" | "HORIZ_BAR" | "DIAG_BAR" | "HORIZ_WITH_TOP_LINE" | "HORIZ_WITH_BOTTOM_LINE" | "VERT_WITH_LEFT_LINE" | "VERT_WITH_RIGHT_LINE" | "CURVE_TO_RIGHT" | "CURVE_TO_TOP" | "CURVE_TO_BOTTOM" | undefined; readonly findLast: { <S extends "DOT" | "HORIZ_BAR" | "DIAG_BAR" | "HORIZ_WITH_TOP_LINE" | "HORIZ_WITH_BOTTOM_LINE" | "VERT_WITH_LEFT_LINE" | "VERT_WITH_RIGHT_LINE" | "CURVE_TO_RIGHT" | "CURVE_TO_TOP" | "CURVE_TO_BOTTOM">(predicate: (value: "DOT" | "HORIZ_BAR" | "DIAG_BAR" | "HORIZ_WITH_TOP_LINE" | "HORIZ_WITH_BOTTOM_LINE" | "VERT_WITH_LEFT_LINE" | "VERT_WITH_RIGHT_LINE" | "CURVE_TO_RIGHT" | "CURVE_TO_TOP" | "CURVE_TO_BOTTOM", index: number, array: readonly ("DOT" | "HORIZ_BAR" | "DIAG_BAR" | "HORIZ_WITH_TOP_LINE" | "HORIZ_WITH_BOTTOM_LINE" | "VERT_WITH_LEFT_LINE" | "VERT_WITH_RIGHT_LINE" | "CURVE_TO_RIGHT" | "CURVE_TO_TOP" | "CURVE_TO_BOTTOM")[]) => value is S, thisArg?: any): S | undefined; (predicate: (value: "DOT" | "HORIZ_BAR" | "DIAG_BAR" | "HORIZ_WITH_TOP_LINE" | "HORIZ_WITH_BOTTOM_LINE" | "VERT_WITH_LEFT_LINE" | "VERT_WITH_RIGHT_LINE" | "CURVE_TO_RIGHT" | "CURVE_TO_TOP" | "CURVE_TO_BOTTOM", index: number, array: readonly ("DOT" | "HORIZ_BAR" | "DIAG_BAR" | "HORIZ_WITH_TOP_LINE" | "HORIZ_WITH_BOTTOM_LINE" | "VERT_WITH_LEFT_LINE" | "VERT_WITH_RIGHT_LINE" | "CURVE_TO_RIGHT" | "CURVE_TO_TOP" | "CURVE_TO_BOTTOM")[]) => unknown, thisArg?: any): "DOT" | "HORIZ_BAR" | "DIAG_BAR" | "HORIZ_WITH_TOP_LINE" | "HORIZ_WITH_BOTTOM_LINE" | "VERT_WITH_LEFT_LINE" | "VERT_WITH_RIGHT_LINE" | "CURVE_TO_RIGHT" | "CURVE_TO_TOP" | "CURVE_TO_BOTTOM" | undefined; }; readonly findLastIndex: (predicate: (value: "DOT" | "HORIZ_BAR" | "DIAG_BAR" | "HORIZ_WITH_TOP_LINE" | "HORIZ_WITH_BOTTOM_LINE" | "VERT_WITH_LEFT_LINE" | "VERT_WITH_RIGHT_LINE" | "CURVE_TO_RIGHT" | "CURVE_TO_TOP" | "CURVE_TO_BOTTOM", index: number, array: readonly ("DOT" | "HORIZ_BAR" | "DIAG_BAR" | "HORIZ_WITH_TOP_LINE" | "HORIZ_WITH_BOTTOM_LINE" | "VERT_WITH_LEFT_LINE" | "VERT_WITH_RIGHT_LINE" | "CURVE_TO_RIGHT" | "CURVE_TO_TOP" | "CURVE_TO_BOTTOM")[]) => unknown, thisArg?: any) => number; readonly toReversed: () => ("DOT" | "HORIZ_BAR" | "DIAG_BAR" | "HORIZ_WITH_TOP_LINE" | "HORIZ_WITH_BOTTOM_LINE" | "VERT_WITH_LEFT_LINE" | "VERT_WITH_RIGHT_LINE" | "CURVE_TO_RIGHT" | "CURVE_TO_TOP" | "CURVE_TO_BOTTOM")[]; readonly toSorted: (compareFn?: ((a: "DOT" | "HORIZ_BAR" | "DIAG_BAR" | "HORIZ_WITH_TOP_LINE" | "HORIZ_WITH_BOTTOM_LINE" | "VERT_WITH_LEFT_LINE" | "VERT_WITH_RIGHT_LINE" | "CURVE_TO_RIGHT" | "CURVE_TO_TOP" | "CURVE_TO_BOTTOM", b: "DOT" | "HORIZ_BAR" | "DIAG_BAR" | "HORIZ_WITH_TOP_LINE" | "HORIZ_WITH_BOTTOM_LINE" | "VERT_WITH_LEFT_LINE" | "VERT_WITH_RIGHT_LINE" | "CURVE_TO_RIGHT" | "CURVE_TO_TOP" | "CURVE_TO_BOTTOM") => number) | undefined) => ("DOT" | "HORIZ_BAR" | "DIAG_BAR" | "HORIZ_WITH_TOP_LINE" | "HORIZ_WITH_BOTTOM_LINE" | "VERT_WITH_LEFT_LINE" | "VERT_WITH_RIGHT_LINE" | "CURVE_TO_RIGHT" | "CURVE_TO_TOP" | "CURVE_TO_BOTTOM")[]; readonly toSpliced: { (start: number, deleteCount: number, ...items: ("DOT" | "HORIZ_BAR" | "DIAG_BAR" | "HORIZ_WITH_TOP_LINE" | "HORIZ_WITH_BOTTOM_LINE" | "VERT_WITH_LEFT_LINE" | "VERT_WITH_RIGHT_LINE" | "CURVE_TO_RIGHT" | "CURVE_TO_TOP" | "CURVE_TO_BOTTOM")[]): ("DOT" | "HORIZ_BAR" | "DIAG_BAR" | "HORIZ_WITH_TOP_LINE" | "HORIZ_WITH_BOTTOM_LINE" | "VERT_WITH_LEFT_LINE" | "VERT_WITH_RIGHT_LINE" | "CURVE_TO_RIGHT" | "CURVE_TO_TOP" | "CURVE_TO_BOTTOM")[]; (start: number, deleteCount?: number): ("DOT" | "HORIZ_BAR" | "DIAG_BAR" | "HORIZ_WITH_TOP_LINE" | "HORIZ_WITH_BOTTOM_LINE" | "VERT_WITH_LEFT_LINE" | "VERT_WITH_RIGHT_LINE" | "CURVE_TO_RIGHT" | "CURVE_TO_TOP" | "CURVE_TO_BOTTOM")[]; }; readonly with: (index: number, value: "DOT" | "HORIZ_BAR" | "DIAG_BAR" | "HORIZ_WITH_TOP_LINE" | "HORIZ_WITH_BOTTOM_LINE" | "VERT_WITH_LEFT_LINE" | "VERT_WITH_RIGHT_LINE" | "CURVE_TO_RIGHT" | "CURVE_TO_TOP" | "CURVE_TO_BOTTOM") => ("DOT" | "HORIZ_BAR" | "DIAG_BAR" | "HORIZ_WITH_TOP_LINE" | "HORIZ_WITH_BOTTOM_LINE" | "VERT_WITH_LEFT_LINE" | "VERT_WITH_RIGHT_LINE" | "CURVE_TO_RIGHT" | "CURVE_TO_TOP" | "CURVE_TO_BOTTOM")[]; readonly [Symbol.iterator]: () => ArrayIterator<"DOT" | "HORIZ_BAR" | "DIAG_BAR" | "HORIZ_WITH_TOP_LINE" | "HORIZ_WITH_BOTTOM_LINE" | "VERT_WITH_LEFT_LINE" | "VERT_WITH_RIGHT_LINE" | "CURVE_TO_RIGHT" | "CURVE_TO_TOP" | "CURVE_TO_BOTTOM">; readonly [Symbol.unscopables]: { readonly [x: number]: boolean | undefined; readonly length?: boolean; readonly toString?: boolean; readonly toLocaleString?: boolean; readonly concat?: boolean; readonly join?: boolean; readonly slice?: boolean; readonly indexOf?: boolean; readonly lastIndexOf?: boolean; readonly every?: boolean; readonly some?: boolean; readonly forEach?: boolean; readonly map?: boolean; readonly filter?: boolean; readonly reduce?: boolean; readonly reduceRight?: boolean; readonly find?: boolean; readonly findIndex?: boolean; readonly entries?: boolean; readonly keys?: boolean; readonly values?: boolean; readonly includes?: boolean; readonly flatMap?: boolean; readonly flat?: boolean; readonly at?: boolean; readonly findLast?: boolean; readonly findLastIndex?: boolean; readonly toReversed?: boolean; readonly toSorted?: boolean; readonly toSpliced?: boolean; readonly with?: boolean; readonly [Symbol.iterator]?: boolean; readonly [Symbol.unscopables]?: boolean; }; readonly ca: "CURVE_TO_LEFT"; }; /** * Converts an affix into script. * * @param cs The Cs of the affix to be converted. * @param degree The degree of the affix. * @param type The type of the affix. * @param slot The slot the affix is placed in. * @param handwritten Whether the outputted characters should be handwritten. * @returns An array of `ConstructableCharacter`s. */ export declare function affixToScript(cs: string | number | bigint, degree: AffixDegree | "ca", type: AffixType, slot: "v" | "vii" | "xi", handwritten?: boolean | undefined): ConstructableCharacter<SecondaryCharacter | NumeralCharacter>[]; /** * Attatches a constructor to a character. * * @param character The character to attach a constructor to. * @param construct The constructor for the character. * @returns The original `character`, updated to have a `construct` property. */ export declare function attachConstructor<T extends Character>(character: T, construct: (character: T) => SVGGElement): ConstructableCharacter<T>; /** Options that modify how a formative is rendered. */ export interface FormativeToScriptOptions { /** Whether the outputted characters should be handwritten. */ readonly handwritten?: boolean | undefined; /** * If `true`, the final quaternary character of a formative representing a * case or an illocution/validation will be replaced by diacritics on the * first secondary character, if possible. * * If `false`, cases and illocutions/validations will not be moved to * diacritics. * * @default true */ readonly useCaseIllValDiacritics?: boolean | undefined; } /** * Converts a formative into script. * * @param formative The formative to be converted. * @param options Options that modify how a formative is rendered. * @returns `ConstructableCharacter`s containing data from which the script can * be constructed. */ export declare function formativeToScript(formative: PartialFormative & { /** Additional affixes which apply to the formative as a whole. */ readonly slotXIAffixes?: readonly Affix[] | undefined; }, options: FormativeToScriptOptions): ConstructableCharacter<Character>[]; /** * Creates a series of characters from `ConstructableCharacter`s. * * @param props Properties defining this character row. * @returns A series of characters. */ export declare function CharacterRow(props: Omit<RowProps, "children"> & { /** The characters to be constructed. */ readonly children: ConstructableCharacter[]; }): SVGElement;