Commit graph

4819 commits

Author SHA1 Message Date
Marc Durdin
e081e0c72e fix(developer): check HISTORY.md to get last modified date for keyboard_info and model_info
This updates the calculation of the lastModifiedDate property of the
.keyboard_info and .model_info file. It now looks for the most recent
commit to HISTORY.md, and then falls back to the project folder for
.keyboard_info and .model_info.

getLastGitCommitDate now also returns UTC date (it was giving TZ=0
which is affected by daylight saving), and works for a file rather than
just for a folder, and a corresponding unit test has been added.

The date strings returned will now always include '.000' msec suffix. I
have manually verified that the import into the api.keyman.com database
copes with this, and that this change still conforms to the expected
schema for .keyboard_info and .model_info files.

Last, but important, it turned out that the unit tests for kmc were not
running. This has been resolved in kmc/build.sh.

Fixes: #11793
2024-06-18 07:03:08 +10:00
Joshua Horton
020bdb4231
Merge pull request #11732 from keymanapp/fix/web/array-from-polyfill
fix(web): add limited Array.from polyfill for lm-worker use
2024-06-14 15:39:30 +07:00
Joshua A. Horton
17787b95ae chore(web): Merge branch 'change/common/update-esbuild' into change/web/lmworker-async-corrections 2024-06-13 12:49:52 +07:00
Joshua A. Horton
ace4eb25c4 chore(common): Merge branch 'master' into change/common/update-esbuild 2024-06-13 12:47:55 +07:00
Joshua Horton
3cf0082a6b
Merge pull request #10343 from keymanapp/change/web/lmworker-async-predict
change(web): prep for better asynchronous prediction handling 🕐
2024-06-13 12:44:50 +07:00
Joshua A. Horton
f2f1c09c84 chore(web): removes ts-node use from gesture-recognizer
Complication: the promise-status library used for testing our promise usage includes a .d.ts file that is not valid with current TS versions.  We now delete theirs and provide our own, fixed version.
2024-06-10 11:04:04 +07:00
Joshua A. Horton
d07fa7e953 chore(common): eliminate ts-node ref from most subpackages 2024-06-10 10:07:58 +07:00
Joshua A. Horton
e527317d3a fix(common): remove subpackge entries for older TS version 2024-06-10 09:14:03 +07:00
Eberhard Beilharz
d231cb045b
Merge pull request #11637 from keymanapp/refactor/web/deprecated
refactor(web): Replace deprecated substr with substring
2024-06-07 16:22:18 +02:00
Joshua A. Horton
062a867ecd change(android): removes unneeded conditionals 2024-06-07 14:24:41 +07:00
Joshua A. Horton
891928e10b fix(web): array.from polyfill scoping, fixes after extracted test 2024-06-07 14:05:12 +07:00
Joshua A. Horton
d66d474f64 fix(web): add limited Array.from polyfill for lm-worker use
Fixes: #11502
Fixes: KEYMAN-WEB-K4
2024-06-07 11:56:18 +07:00
Marc Durdin
32e92846a3
Merge pull request #11690 from keymanapp/chore/common/move-cldr-import-copy-to-build-step
chore(common): move CLDR import copy into build step for common/web/types
2024-06-06 10:08:39 +07:00
Marc Durdin
23f9391855
Merge pull request #11660 from keymanapp/chore/8616-bring-xml2js-into-repo
chore: move xml2js into the repo to eliminate npm git dependency
2024-06-06 10:02:32 +07:00
Marc Durdin
f2e0398c13
Merge pull request #11657 from keymanapp/chore/8616-remove-restructure-git-dep
chore: replace git dep on restructure with 3.0.1 in npm
2024-06-06 10:02:22 +07:00
Joshua A. Horton
950b2780c3 change(web): converts correction-search to use of async generator 2024-06-05 12:30:19 +07:00
Joshua A. Horton
cb0a60165c change(common): updates esbuild to 0.18.9 2024-06-05 12:09:53 +07:00
Marc Durdin
93ba57dcd8 chore(common): move CLDR import copy into build step for common/web/types
The CLDR imports are copied into the build/ folder, so it makes more
sense for them to be done during the build phase, particularly as it is
a very quick operation. (Before this, removing the build/ folder did not
trigger a build.sh configure, so subsequent tests and usage will fail
with confusing LDML import errors. An alternative solution would have
been to declare the configure output to be one of these files.)
2024-06-05 10:53:44 +07:00
Marc Durdin
9c204ea071 fix(common): import EventEmitter only instead of all events in parser.js
When importing all of events with:

    import * as events from 'events';

tsc for kmc-ldml (but not for common/web/types) would error with:

    ../../../common/web/types/build/src/deps/xml2js/parser.d.ts:17:25 - error TS2306: File '.../node_modules/@types/node/events.d.ts' is not a module.

    17 import * as events from "node/events.js";

I am not clear why. Changing to the following side-stepped this:

    import { EventEmitter } from 'events';
2024-06-05 10:07:37 +07:00
Joshua A. Horton
d6f05323f8 fix(web): fix predictions after moving caret
Fixes: #11684
Fixes: KEYMAN-WEB-KR
Fixes: #11620
Fixes: KEYMAN-WEB-KT
2024-06-05 08:41:27 +07:00
Marc Durdin
e6d59fc173 chore: move xml2js into the repo to eliminate npm git dependency
Small rewrites to the xml2js code as ES6 modules. Based on
https://github.com/keymanapp/dependency-node-xml2js

Fixes: #8616
2024-06-03 16:07:29 +07:00
Joshua A. Horton
e5f2fbd10e chore(web): Merge branch 'master' into change/web/lmworker-async-predict 2024-06-03 15:20:39 +07:00
Joshua Horton
c3277c5fdf
Merge pull request #11464 from keymanapp/chore/web/final-config-flag-fixes
chore(web): finalize web/ project parity with base-repo TS config settings (aside from JS version target) 🔩
2024-06-03 15:16:35 +07:00
Joshua Horton
f5e65f0539
Merge pull request #11462 from keymanapp/chore/web/remove-no-implicit-any
chore(web): correct cases of implicit-any in web/ 🔩
2024-06-03 15:16:10 +07:00
Joshua Horton
604d2fcb11
Merge pull request #11424 from keymanapp/chore/web/partial-config-cleanup
chore(web): clean up remaining low-level Web .tsconfig settings 🔩
2024-06-03 15:16:00 +07:00
Marc Durdin
b874de25e8 chore: replace git dep on restructure with 3.0.1 in npm
3.0.1 includes our fix. However, 3.0.2 does not yet appear to have been
published, which has a patch for our fix?

Fixes: #8616
2024-06-03 14:58:39 +07:00
Eberhard Beilharz
47e8d3db57
Merge pull request #11594 from keymanapp/fix/web/11593_undefinedConfig
fix(web): Don't apply suggestion unless fully configured
2024-06-03 09:01:22 +02:00
Joshua A. Horton
eb40a0f6ee chore(web): Merge remote-tracking branch 'origin/chore/web/remove-no-implicit-any' into chore/web/remove-no-implicit-any 2024-06-03 11:58:06 +07:00
Joshua A. Horton
d2987ac26f chore(web): Merge branch 'chore/web/partial-config-cleanup' into chore/web/remove-no-implicit-any 2024-06-03 11:57:33 +07:00
Joshua A. Horton
46e4518749 chore(web): Merge branch 'master' into chore/web/partial-config-cleanup 2024-06-03 10:57:51 +07:00
Joshua Horton
b304069425
Merge pull request #11603 from keymanapp/fix/web/kbd-proc-strictness-bugs
fix(web): fix keyboard-processing bugs uncovered by stricter TS settings 🔩
2024-06-03 10:55:10 +07:00
Joshua Horton
b6207dca45
Merge pull request #11601 from keymanapp/refactor/web/typed-property-transplantation
refactor(web): refactor keyboard-layout preprocessing property transplantation 🔩
2024-06-03 10:55:02 +07:00
Joshua A. Horton
3d77cf2fef docs(web): on KLS format and its arrays of 65 entries 2024-06-03 08:38:12 +07:00
Eberhard Beilharz
3ee8359f8f
refactor(web): Replace deprecated substr with slice
Also add a comment to `SourcemappedWorker` explaining the difference
to `DefaultWorker`.
2024-05-31 11:27:55 +02:00
Eberhard Beilharz
9cac9772dc
Update common/web/input-processor/src/text/prediction/languageProcessor.ts
Co-authored-by: Joshua Horton <joshua_horton@sil.org>
2024-05-31 10:57:04 +02:00
Joshua Horton
2b33d6c0a5
docs(web): tweaks comment regarding a @ts-ignore
Co-authored-by: Marc Durdin <marc@durdin.net>
2024-05-31 15:14:33 +07:00
Joshua A. Horton
5abd621ddc change(web): isKeyNotCorrected -> isFrameKey 2024-05-31 13:58:31 +07:00
Marc Durdin
4cc6c3699f
Merge pull request #11611 from keymanapp/chore/windows/support-port-in-httpuploader
chore(windows): support port in THTTPUploader
2024-05-31 13:07:46 +07:00
Marc Durdin
ab1e916086
Merge pull request #11590 from keymanapp/fix/developer/11589-single-pixel-top-row-for-touch-on-character-map
fix(developer): make top row of Character Map 1 pixel to avoid DIV/0 in gestures
2024-05-31 13:07:21 +07:00
Joshua Horton
c4932b7fd1
docs(web): adds suggested documentation from code review
Co-authored-by: Marc Durdin <marc@durdin.net>
2024-05-31 10:06:05 +07:00
Joshua Horton
8f3569681b
docs(web): Update codes.ts with docs on use of the 50000 literal 2024-05-30 16:56:30 +07:00
Joshua Horton
006f15b225
change(web): minor simplification from review
Co-authored-by: Marc Durdin <marc@durdin.net>
2024-05-30 16:53:17 +07:00
Joshua A. Horton
487a28da8e docs(web): for EncodedVisualKeyboard 2024-05-30 16:44:27 +07:00
Joshua A. Horton
10033f4dea docs(web): fixes detail about readonly keystroke params 2024-05-30 16:40:59 +07:00
Joshua A. Horton
61dfcc98f6 docs(web): documents KeyboardObject properties 2024-05-30 16:37:00 +07:00
Joshua Horton
ee0c107afe
fix(web): for...of, not for...in
We moved to the Object.keys() pattern, which means replacing the 'in'

Co-authored-by: Marc Durdin <marc@durdin.net>
2024-05-30 15:58:57 +07:00
Joshua Horton
321ded4776
Merge pull request #11460 from keymanapp/chore/web/remove-unused-locals
chore(web): removes unused locals, imports, and private fields 🔩
2024-05-30 15:50:45 +07:00
Joshua Horton
da4cf64ebf
Merge pull request #11598 from keymanapp/fix/web/worker-prediction-match-token
fix(web): use intended source for prediction-to-context matching 🔩
2024-05-30 15:50:31 +07:00
Joshua Horton
dbee817d80
Merge pull request #11459 from keymanapp/chore/web/fix-implicit-this
chore(web): fixes implicit-this cases 🔩
2024-05-30 15:50:24 +07:00
Joshua Horton
f283d955a7
Merge pull request #11596 from keymanapp/fix/web/recorder-core-strictness
fix(web): headless recorder unhandled paths, invalid test-sequence references 🔩
2024-05-30 15:50:12 +07:00