fixed error on inflection table

This commit is contained in:
adueck 2024-06-13 15:00:47 -04:00
parent 7b3ac0dab9
commit 2d8fd52aae
7 changed files with 21 additions and 21 deletions

4
package-lock.json generated
View File

@ -1,12 +1,12 @@
{
"name": "pashto-inflector",
"version": "7.1.1",
"version": "7.1.2",
"lockfileVersion": 2,
"requires": true,
"packages": {
"": {
"name": "pashto-inflector",
"version": "7.1.1",
"version": "7.1.2",
"hasInstallScript": true,
"license": "MIT",
"dependencies": {

View File

@ -1,6 +1,6 @@
{
"name": "pashto-inflector",
"version": "7.1.1",
"version": "7.1.2",
"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",

View File

@ -16,11 +16,11 @@ import useStickyState from "./components/src/useStickyState";
import EPExplorer from "./components/src/ep-explorer/EPExplorer";
import VPBuilderDemo from "./demo-components/VPBuilderDemo";
import { entryFeeder } from "./demo-components/entryFeeder";
import { Hider, inflectWord } from "./components/library";
import Hider from "./components/src/Hider";
import InflectionDemo from "./demo-components/InflectionDemo";
import SpellingDemo from "./demo-components/SpellingDemo";
import ParserDemo from "./demo-components/ParserDemo";
// import InflectionTable from "./components/src/InflectionsTable";
import InflectionTable from "./components/src/InflectionsTable";
function App() {
const [showingTextOptions, setShowingTextOptions] = useStickyState<boolean>(
@ -40,17 +40,16 @@ function App() {
document.documentElement.setAttribute("data-theme", theme);
}, [theme]);
const infout = inflectWord({
ts: 1527815306,
i: 9623,
p: "ستړی",
f: "stúRay",
g: "stuRay",
e: "tired",
r: 4,
c: "adj. / adv.",
a: 1,
});
// const infout = inflectWord({
// ts: 1527814202,
// i: 12761,
// p: "کرسي",
// f: "kUrsee",
// g: "kUrsee",
// e: "chair, seat, stool",
// r: 3,
// c: "n. f.",
// });
return (
<>

View File

@ -1,12 +1,12 @@
{
"name": "@lingdocs/ps-react",
"version": "7.1.1",
"version": "7.1.2",
"lockfileVersion": 2,
"requires": true,
"packages": {
"": {
"name": "@lingdocs/ps-react",
"version": "7.1.1",
"version": "7.1.2",
"license": "MIT",
"dependencies": {
"@formkit/auto-animate": "^1.0.0-beta.3",

View File

@ -1,6 +1,6 @@
{
"name": "@lingdocs/ps-react",
"version": "7.1.1",
"version": "7.1.2",
"description": "Pashto inflector library module with React components",
"main": "dist/components/library.js",
"module": "dist/components/library.js",

View File

@ -53,6 +53,7 @@ const InflectionTable = ({
// const handleCloseExplanation = () => setShowingExplanation(false);
// const handleShowExplanation = () => setShowingExplanation(true);
const isPluralInfs = isPluralInflections(inf);
console.log({ inf });
return (
<div className={!hideTitle ? "" : "mt-4"}>
{!hideTitle && (
@ -117,7 +118,7 @@ const InflectionTable = ({
center
/>
)}
{"fem" in inf && i < 2 && (
{"fem" in inf && (!("masc" in inf) || i < 2) && (
<TableCell item={inf.fem[i]} textOptions={textOptions} center />
)}
</tr>

View File

@ -1,6 +1,6 @@
{
"name": "@lingdocs/inflect",
"version": "7.1.1",
"version": "7.1.2",
"description": "Pashto inflector library",
"main": "dist/index.js",
"types": "dist/lib/library.d.ts",