From ef120b13aa2822e113c38281e2c2c915e191a0e2 Mon Sep 17 00:00:00 2001 From: adueck Date: Sun, 3 Dec 2023 20:43:24 +0400 Subject: [PATCH] =?UTF-8?q?fix=20=D8=B4=D9=88=20-=20sho=20problem=20with?= =?UTF-8?q?=20verbs?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .github/workflows/test-nix.yml | 18 ------------------ package-lock.json | 4 ++-- package.json | 2 +- src/components/package-lock.json | 4 ++-- src/components/package.json | 2 +- src/lib/package.json | 2 +- src/lib/src/new-verb-engine/render-verb.ts | 12 +++++++++++- 7 files changed, 18 insertions(+), 26 deletions(-) delete mode 100644 .github/workflows/test-nix.yml diff --git a/.github/workflows/test-nix.yml b/.github/workflows/test-nix.yml deleted file mode 100644 index e84eaea..0000000 --- a/.github/workflows/test-nix.yml +++ /dev/null @@ -1,18 +0,0 @@ -name: "Test Nix" -on: - pull_request: - push: -jobs: - tests: - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v3 - - uses: cachix/install-nix-action@v18 - with: - nix_path: nixpkgs = fetchTarball "https://github.com/NixOS/nixpkgs/tarball/nixos-23.05" - - uses: workflow/nix-shell-action@v3 - with: - packages: nodejs_20,pandoc - script: | - node --version - pandoc --version diff --git a/package-lock.json b/package-lock.json index 8aaf366..d3a223d 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,12 +1,12 @@ { "name": "pashto-inflector", - "version": "6.0.11", + "version": "6.0.12", "lockfileVersion": 2, "requires": true, "packages": { "": { "name": "pashto-inflector", - "version": "6.0.11", + "version": "6.0.12", "hasInstallScript": true, "license": "MIT", "dependencies": { diff --git a/package.json b/package.json index 8eadeda..1efc8bc 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "pashto-inflector", - "version": "6.0.11", + "version": "6.0.12", "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/components/package-lock.json b/src/components/package-lock.json index 2374f22..3732872 100644 --- a/src/components/package-lock.json +++ b/src/components/package-lock.json @@ -1,12 +1,12 @@ { "name": "@lingdocs/ps-react", - "version": "6.0.11", + "version": "6.0.12", "lockfileVersion": 2, "requires": true, "packages": { "": { "name": "@lingdocs/ps-react", - "version": "6.0.11", + "version": "6.0.12", "license": "MIT", "dependencies": { "@formkit/auto-animate": "^1.0.0-beta.3", diff --git a/src/components/package.json b/src/components/package.json index d7bf5c8..e1173a6 100644 --- a/src/components/package.json +++ b/src/components/package.json @@ -1,6 +1,6 @@ { "name": "@lingdocs/ps-react", - "version": "6.0.11", + "version": "6.0.12", "description": "Pashto inflector library module with React components", "main": "dist/components/library.js", "module": "dist/components/library.js", diff --git a/src/lib/package.json b/src/lib/package.json index 349cdb7..ea17f13 100644 --- a/src/lib/package.json +++ b/src/lib/package.json @@ -1,6 +1,6 @@ { "name": "@lingdocs/inflect", - "version": "6.0.11", + "version": "6.0.12", "description": "Pashto inflector library", "main": "dist/index.js", "types": "dist/lib/library.d.ts", diff --git a/src/lib/src/new-verb-engine/render-verb.ts b/src/lib/src/new-verb-engine/render-verb.ts index 7cf8739..d53fd68 100644 --- a/src/lib/src/new-verb-engine/render-verb.ts +++ b/src/lib/src/new-verb-engine/render-verb.ts @@ -272,8 +272,8 @@ function addEnding({ vb: T.VBBasic, end: T.SingleOrLengthOpts ): T.VBBasic { - // exceptional ending for راتلل, ورتلل, درتلل if ("long" in vb.ps) { + // exceptional ending for راتلل, ورتلل, درتلل // TODO: do we need a more thorough check? if (vb.ps.short[0].f === "ghl" && pastThird && basicForm) { return { @@ -281,6 +281,16 @@ function addEnding({ ps: [{ p: "غی", f: "ghay" }], }; } + // exceptional ending for شو + if (vb.ps.short[0].f === "shw" && pastThird) { + return { + ...vb, + ps: { + short: [{ p: "شو", f: "sho" }], + long: [{ p: "شولو", f: "shwulo" }], + }, + }; + } } const endShort = getLength(end, "short");