From 7275fbd73c2e56ecbbfbeff7952e6959069696a0 Mon Sep 17 00:00:00 2001 From: lingdocs <71590811+lingdocs@users.noreply.github.com> Date: Thu, 23 Jun 2022 16:19:44 -0500 Subject: [PATCH] hmm --- package.json | 2 +- src/lib/phrase-building/compile.ts | 3 +-- src/library.ts | 7 ++++++- 3 files changed, 8 insertions(+), 4 deletions(-) diff --git a/package.json b/package.json index b4b1639..855a141 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "@lingdocs/pashto-inflector", - "version": "3.0.8", + "version": "3.0.9", "author": "lingdocs.com", "description": "A Pashto inflection and verb conjugation engine, inculding React components for displaying Pashto text, inflections, and conjugations", "homepage": "https://verbs.lingdocs.com", diff --git a/src/lib/phrase-building/compile.ts b/src/lib/phrase-building/compile.ts index da0630a..9f38c88 100644 --- a/src/lib/phrase-building/compile.ts +++ b/src/lib/phrase-building/compile.ts @@ -268,7 +268,7 @@ function compileEnglishVP(VP: T.VPRendered): string[] | undefined { : undefined; const engAPs = getEngAPs(VP.blocks); // require all English parts for making the English phrase - const b = (VP.englishBase && engSubj && engObj !== undefined) + return (VP.englishBase && engSubj && engObj !== undefined) ? VP.englishBase.map(e => insertEWords(e, { // TODO: make sure we actually have the english subject: getEnglishFromRendered(engSubj) || "", @@ -276,7 +276,6 @@ function compileEnglishVP(VP: T.VPRendered): string[] | undefined { APs: engAPs, })).map(capitalizeFirstLetter) : undefined; - return b; } function compileEnglishEP(EP: T.EPRendered): string[] | undefined { diff --git a/src/library.ts b/src/library.ts index c123403..e0bcf7d 100644 --- a/src/library.ts +++ b/src/library.ts @@ -28,6 +28,8 @@ import Hider from "./components/Hider"; import EntrySelect from "./components/EntrySelect"; import VerbInfo, { RootsAndStems } from "./components/verb-info/VerbInfo"; import VPExplorer from "./components/vp-explorer/VPExplorer"; +import { vpsReducer } from "./components/vp-explorer/vps-reducer"; +import type { VpsReducerAction as VpsA } from "./components/vp-explorer/vps-reducer"; import useStickyState from "./lib/useStickyState"; import Block, { NPBlock, APBlock } from "./components/blocks/Block"; import { roleIcon } from "./components/vp-explorer/VPExplorerExplanationModal"; @@ -232,6 +234,7 @@ export { renderAPSelection, getEnglishVerb, roleIcon, + vpsReducer, // protobuf helpers readDictionary, writeDictionary, @@ -272,4 +275,6 @@ export { genderColors, // TYPES Types, -} \ No newline at end of file +} + +export type VpsReducerAction = VpsA; \ No newline at end of file