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.

71 lines (70 loc) 4.69 kB
/** An object containing all diacritics and their SVG paths. */ export declare const CORE_DIACRITICS: { readonly DOT: "M 0 0 l 7.5 7.5 l 7.5 -7.5 l -7.5 -7.5 l -7.5 7.5 z"; readonly HORIZ_BAR: "M 0 0 l 10 -10 l -30 0 l -10 10 l 30 0 z"; readonly VERT_BAR: "M 0 0 l -10 10 l 0 25 l 10 -10 l 0 -25 z"; readonly DIAG_BAR: "M 0 0 l 20 20 l 7.5 -7.5 l -20 -20 l -7.5 7.5 z"; readonly TWO_PART_DIAG_BAR: "M 0 0 l 12.5 12.5 l -15 0 l -10 10 l 30 0 l 10 -10 l -20 -20 l -7.5 7.5 z"; readonly HORIZ_WITH_TOP_LINE: "M 0 0 l 8.8 -8.8 l -1.2 -1.2 l -20 20 l 30 0 l 10 -10 l -27.6 0 z"; readonly HORIZ_WITH_BOTTOM_LINE: "M 0 0 l -8.8 8.8 l 1.2 1.2 l 20 -20 l -30 0 l -10 10 l 27.6 0 z"; readonly VERT_WITH_LEFT_LINE: "M 0 0 l 0 -25 l -20 20 l 1.2 1.2 l 8.8 -8.8 l 0 22.6 l 10 -10 z"; readonly VERT_WITH_RIGHT_LINE: "M 0 0 l 0 25 l 20 -20 l -1.2 -1.2 l -8.8 8.8 l 0 -22.6 l -10 10 z"; readonly CURVE_TO_LEFT: "M 0 0 l -1.15 -1.25 q -6.55 11.7 -14.4 12.25 q -7.8 0.5 -17.45 -9.75 l -7.5 7.5 q 6.55 12.05 18.7 9.55 q 12.25 -2.5 21.8 -18.3 z"; readonly CURVE_TO_RIGHT: "M 0 0 l 1.15 1.25 q 6.55 -11.7 14.4 -12.25 q 7.8 -0.5 17.45 9.75 l 7.5 -7.5 q -6.55 -12.05 -18.7 -9.55 q -12.25 2.5 -21.8 18.3 z"; readonly CURVE_TO_TOP: "M 0 0 q -0.75 -5.3 -5.4 -8.4 q -4.9 -3.3 -12.95 -3.2 l -7.5 7.5 q 14.9 0.4 18.6 8.55 q 3.75 8.2 -7.45 16.9 l 1.25 1.15 q 7.35 -5.2 10.9 -11.4 q 3.3 -5.85 2.55 -11.1 z"; readonly CURVE_TO_BOTTOM: "M 0 0 q 0.75 5.3 5.4 8.4 q 4.9 3.3 12.95 3.2 l 7.5 -7.5 q -14.9 -0.4 -18.6 -8.55 q -3.75 -8.2 7.45 -16.9 l -1.25 -1.15 q -7.35 5.2 -10.9 11.4 q -3.3 5.85 -2.55 11.1 z"; readonly CURVE_TO_BOTTOM_WITH_LINE: "M 0 0 q -3.3 5.85 -2.55 11.1 q 0.75 5.3 5.4 8.4 q 4.162 2.803 10.6 3.15 l -8.85 8.85 l 1.2 1.2 l 17.5 -17.5 q -14.9 -0.4 -18.6 -8.55 q -3.75 -8.2 7.45 -16.9 l -1.25 -1.15 q -7.35 5.2 -10.9 11.4 z"; readonly CURVE_TO_LEFT_WITH_DOT: "M 0 0 l -1.15 -1.25 q -6.55 11.7 -14.4 12.25 q -7.8 0.5 -17.45 -9.75 l -7.5 7.5 q 6.55 12.05 18.7 9.55 q 12.25 -2.5 21.8 -18.3 m -9.6 -1.25 l -7.5 -7.5 l -7.5 7.5 l 7.5 7.5 l 7.5 -7.5 z"; readonly CURVE_TO_RIGHT_WITH_DOT: "M 0 0 l 1.15 1.25 q 6.55 -11.7 14.4 -12.25 q 7.8 -0.5 17.45 9.75 l 7.5 -7.5 q -6.55 -12.05 -18.7 -9.55 q -12.25 2.5 -21.8 18.3 m 9.6 1.25 l 7.5 7.5 l 7.5 -7.5 l -7.5 -7.5 l -7.5 7.5 z"; readonly a: "M 0 0 l 7.5 7.5 l 7.5 -7.5 l -7.5 -7.5 l -7.5 7.5 z"; readonly ä: "M 0 0 l 10 -10 l -30 0 l -10 10 l 30 0 z"; readonly e: "M 0 0 l -8.8 8.8 l 1.2 1.2 l 20 -20 l -30 0 l -10 10 l 27.6 0 z"; readonly ë: "M 0 0 l 8.8 -8.8 l -1.2 -1.2 l -20 20 l 30 0 l 10 -10 l -27.6 0 z"; readonly i: "M 0 0 l 20 20 l 7.5 -7.5 l -20 -20 l -7.5 7.5 z"; readonly o: "M 0 0 q -0.75 -5.3 -5.4 -8.4 q -4.9 -3.3 -12.95 -3.2 l -7.5 7.5 q 14.9 0.4 18.6 8.55 q 3.75 8.2 -7.45 16.9 l 1.25 1.15 q 7.35 -5.2 10.9 -11.4 q 3.3 -5.85 2.55 -11.1 z"; readonly ö: "M 0 0 q 0.75 5.3 5.4 8.4 q 4.9 3.3 12.95 3.2 l 7.5 -7.5 q -14.9 -0.4 -18.6 -8.55 q -3.75 -8.2 7.45 -16.9 l -1.25 -1.15 q -7.35 5.2 -10.9 11.4 q -3.3 5.85 -2.55 11.1 z"; readonly u: "M 0 0 l 0 25 l 20 -20 l -1.2 -1.2 l -8.8 8.8 l 0 -22.6 l -10 10 z"; readonly ü: "M 0 0 l 0 -25 l -20 20 l 1.2 1.2 l 8.8 -8.8 l 0 22.6 l 10 -10 z"; }; /** An object containing all handwritten diacritics. */ export declare const HANDWRITTEN_DIACRITICS: { readonly DOT: string; readonly HORIZ_BAR: string; readonly VERT_BAR: string; readonly DIAG_BAR: string; readonly TWO_PART_DIAG_BAR: string; readonly HORIZ_WITH_TOP_LINE: string; readonly HORIZ_WITH_BOTTOM_LINE: string; readonly VERT_WITH_LEFT_LINE: string; readonly VERT_WITH_RIGHT_LINE: string; readonly CURVE_TO_LEFT: string; readonly CURVE_TO_RIGHT: string; readonly CURVE_TO_TOP: string; readonly CURVE_TO_BOTTOM: string; readonly CURVE_TO_BOTTOM_WITH_LINE: string; readonly CURVE_TO_LEFT_WITH_DOT: string; readonly CURVE_TO_RIGHT_WITH_DOT: string; readonly a: string; readonly ä: string; readonly e: string; readonly ë: string; readonly i: string; readonly o: string; readonly ö: string; readonly u: string; readonly ü: string; }; /** The name of a diacritic. */ export type DiacriticName = keyof typeof CORE_DIACRITICS; /** * Instantiates a diacritic into an SVG path. * * @param props Properties that modify the output of this `Diacritic`. * @returns An `SVGPathElement` containing the diacritic. */ export declare function Diacritic(props: { /** Whether this diacritic is handwritten. */ readonly handwritten?: boolean | undefined; /** The name of the diacritic to draw. */ readonly name: DiacriticName; }): SVGPathElement;