Commit graph

1115 commits

Author SHA1 Message Date
Marc Durdin
c524db41b9 maint(common): use builder_launch for child builds
Fixes: #15130
Test-bot: skip
2025-12-02 06:17:31 +01:00
Eberhard Beilharz
408514daf3
Update web/src/engine/js-processor/src/deadkeys.ts
Co-authored-by: Marc Durdin <marc@durdin.net>
2025-11-10 12:00:28 +01:00
Eberhard Beilharz
269d619ed9
docs(web): add another clarifying comment 2025-11-07 17:32:33 +01:00
Eberhard Beilharz
03831e4f25
fix(web): clarify meaning of parameters for isMatch 2025-11-07 13:47:23 +01:00
Eberhard Beilharz
98ed960c8f
fix(web): address code review comments 2025-11-07 13:22:45 +01:00
Eberhard Beilharz
28d3378589
fix(web): add unit tests for DeadkeyTracker and fix a few bugs
- initialize `Deadkey.matched` in c'tor
- fix `Deadkey.equal` method
- verify deadkey exists before removing it in `DeadkeyTracker.remove`
- add unit tests for DeadkeyTracker

Test-bot: skip
2025-11-07 12:09:54 +01:00
Eberhard Beilharz
229bdf8270
maint(resources): nest unit tests under parent block
This adds a modified `mocha-teamcity-reporter` that allows to nest the
unit tests under the parent block.

Fixes: #14839
Test-bot: skip
2025-10-06 16:09:47 +02:00
Eberhard Beilharz
34c43b1e15
refactor(web): cleanup in test scripts
Also use common function for running web types tests.

Test-bot: skip
2025-09-30 17:40:15 +02:00
Eberhard Beilharz
f464008326
fix(web): add check to internalHeight
The same error could potentially happen in `internalHeight`, so we
add the check for NaN there as well. Addresses code review comments.
2025-09-05 09:35:50 +02:00
Eberhard Beilharz
74ef39726b
fix(web): fix error trying to calculate style scaling effects
PR #13860 fixed a similar error by adding a check for NaN. However, it
missed doing it for `layoutWidth` and only changed `layoutHeight`. This
PR adds a similar check to `layoutWidth` and will thus fix the error
we're still seeing in Sentry.

Also add unit tests for both methods.

User Testing
============

TEST_INUKTITUT_KEYBOARD: Using Keyman for Android, install the
`inuktitut_pirurvik` and verify that no error notifications appear.

Fixes: #14108
Fixes: [KEYMAN-WEB-RA](https://keyman.sentry.io/issues/6579536471/?referrer=github_integration)
2025-09-04 17:28:15 +02:00
Joshua Horton
191db9cba9
Merge pull request #14618 from keymanapp/refactor/web/simplify-calculation-inputs
refactor(web): simplify edit-distance calculation-object inputs
2025-09-03 22:11:00 +07:00
Joshua Horton
770ac2a13f
Merge pull request #14592 from keymanapp/feat/web/search-subset-batching
feat(web): batch correction-search paths by related subsets
2025-09-03 22:10:46 +07:00
Joshua Horton
33ae31f3a4 fix(web): prevent undefined traversal entry 2025-08-28 09:32:48 -05:00
Joshua Horton
1942309356 feat(web): add unit test for empty-char inputs, matches 2025-08-28 09:15:47 -05:00
Joshua Horton
d9aebf0213 Merge branch 'feat/web/search-subset-batching' into refactor/web/simplify-calculation-inputs 2025-08-28 09:10:11 -05:00
Joshua Horton
820c082839
docs(web): Apply comment-oriented suggestions from code review
Co-authored-by: Marc Durdin <marc@durdin.net>
2025-08-28 21:03:52 +07:00
Joshua Horton
9f54ab1b25
change(web): add missing semi-colon
Co-authored-by: Marc Durdin <marc@durdin.net>
2025-08-28 20:57:39 +07:00
Joshua Horton
82c35d0b97 refactor(web): simplify calculation-object inputs 2025-08-27 16:40:45 -05:00
Joshua Horton
a08390750f refactor(web): track traversal history on search node, not calculation object 2025-08-27 16:08:27 -05:00
Joshua Horton
129470c5ca docs(web): processSubsetEdge comment enhancements 2025-08-25 11:17:17 -05:00
Joshua Horton
c573f26e23 docs(web): clean up comments added during subset-batch PR work 2025-08-25 10:54:11 -05:00
Joshua Horton
0c3c58ae5d docs(web): adds PartialSearchEdge type doc comment 2025-08-25 10:48:04 -05:00
Joshua Horton
057b6cbc1b refactor(web): place all partial-edge properties under single object-based property 2025-08-25 08:48:48 -05:00
Joshua Horton
aa9df34623 feat(web): batch correction-search paths by related subsets
This change should dramatically cut down on the number of heavily-mismatched paths that the correction-search engine builds during operation.  Now, whenever input characters are being matched against a character from the lexicon, they're all replaced, **together**, with a single sentinel character instance that represents them all together - with their exact accumulated probability mass.

Doing so dramatically cuts down on the rate of memory use expansion during correction-search's operation... and likely cuts down on execution time on average, allowing for more potential corrections to be considered.
2025-08-22 18:23:13 -05:00
Joshua Horton
e20bd8ebd9 feat(web): adds transform subset-building methods to predictive-text worker
These methods place a set of input Transforms into multiple subsets with common properties.  They're designed for use in upcoming enhancements to the predictive-text worker's correction-search approach.
2025-08-22 15:38:55 -05:00
Joshua Horton
e17e014815 docs(web): improve documentation for SearchSpace and SearchNode 2025-08-19 10:49:15 -05:00
Marc Durdin
81c807c257 chore(common): Merge branch 'master' into maint/common/14453-move-ci-scripts 2025-08-19 10:46:11 +02:00
Joshua Horton
6d27c3468d Merge branch 'refactor/web/apply-suggestion-casing' into maint/web/convert-worker-thread-tests 2025-08-14 11:01:39 -05:00
Joshua Horton
51fc6f636f Merge branch 'fix/web/suggestion-typing' into refactor/web/apply-suggestion-casing 2025-08-14 11:00:11 -05:00
Joshua Horton
aa77e4ca0b fix(web): remove unneeded sort from unit test 2025-08-14 10:59:45 -05:00
Joshua Horton
981905717a change(web): add MAX_PROB constant for use in 'keep'-suggestion construction 2025-08-14 08:23:40 -05:00
Joshua Horton
ae469ed1b4
change(web): apply suggestion from code-review
Co-authored-by: Marc Durdin <marc@durdin.net>
2025-08-14 20:19:53 +07:00
Joshua Horton
c3124ec685 change(web): use contextTracker getter internally 2025-08-13 10:57:16 -05:00
Joshua Horton
ec888dd751 Merge branch 'refactor/web/apply-suggestion-casing' into maint/web/convert-worker-thread-tests 2025-08-13 10:52:57 -05:00
Joshua Horton
519e39e327 refactor(web): move applySuggestionCasing to standalone exportable method 2025-08-13 10:45:15 -05:00
Joshua Horton
e24deefdb8 fix(web): improve typing accuracy for suggestions & suggestion-generation
Also adds doc-comments to a couple of the related types
2025-08-13 10:27:13 -05:00
Joshua Horton
a01211efa4 change(web): improve exposure of once-private members 2025-08-13 08:49:41 -05:00
Joshua Horton
e9a1f6c349 maint(web): converts worker-thread tests to TS 2025-08-12 15:38:53 -05:00
Joshua Horton
88f3a1a716 maint(web): convert models-templates, models-wordbreakers unit tests to TS 2025-08-12 10:12:10 -05:00
Marc Durdin
942b06afdd
Merge pull request #14451 from keymanapp/maint/common/14447-node.inc.sh
maint(common): rename and move node-related script functions into node.inc.sh 🐸
2025-08-12 10:41:18 +07:00
Marc Durdin
a81138c62b
Merge pull request #14449 from keymanapp/maint/common/14065-consolidate-builder-scripts
maint(common): consolidate builder scripts 🐸
2025-08-12 10:41:09 +07:00
Marc Durdin
f95b26ac1f
Merge pull request #14446 from keymanapp/maint/common/14275-rename-and-cleanup-shellHelperFunctions.sh
maint(common): rename shellHelperFunctions.sh to utils.inc.sh 🐸
2025-08-12 10:40:59 +07:00
Joshua Horton
09611146dc fix(web): legacy model unit tests should use an actual legacy model 2025-08-05 10:27:48 -05:00
Marc Durdin
f3fb3ac87b maint(common): move build-utils-ci.inc.sh to ci/ci-publish.inc.sh
Removes a number of unused functions from the file, renames remaining
functions to match our builder script prefix patterns, removes unused
imports from various build scripts (e.g. Android).

Fixes: #14453
2025-08-05 12:54:56 +10:00
Marc Durdin
2726050601 maint(common): rename and move node-related script functions into node.inc.sh
Consolidates the node-related script functions into node.inc.sh, as part
of cleaning up the build scripts and making them easier to maintain into
the future.

Fixes: #14447
2025-08-02 13:34:29 +10:00
Marc Durdin
f394245636 maint(common): consolidate builder scripts
Clarifies the confusing builder.inc.sh / build-utils.sh distinction by
giving the scripts more appropriate names. Most build scripts should use
builder-full.inc.sh; some helper scripts can use builder-basic.inc.sh.
Documented in resources/build/README.md.

Renames:
* resources/build/builder.inc.sh to resources/build/builder-full.inc.sh
* resources/build/build-utils.sh to resources/build/builder-basic.inc.sh

Other changes:
* Moves Android-specific functions out of builder-basic.inc.sh and into
  android/build.sh.
* Renames functions in builder-basic.inc.sh

More functions may be moved from builder-basic.inc.sh into utils.inc.sh
or other scripts in the future.

Fixes: #14065
Build-bot: build all
Test-bot: skip
2025-08-02 08:11:24 +10:00
Marc Durdin
65158a0526 maint(common): rename shellHelperFunctions.sh to utils.inc.sh
Adds documentation for various functions, removes unused functions (a
couple of simple, very lightly used functions were unDRYed; these could
go back the other way across all shell scripts if necessary). TODO items
noted for follow-up refactoring.

Fixes: #14275
Relates-to: #14269
Build-bot: build all
Test-bot: skip
2025-08-02 06:58:40 +10:00
Eberhard Beilharz
5969d8e693
Apply suggestions from code review
Co-authored-by: Marc Durdin <marc@durdin.net>
2025-07-03 12:47:52 +02:00
Eberhard Beilharz
307ae20790
refactor(web): move helper functions to beginning of function
The previous code showed a warning in the Firefox console: "Unreachable
code after return statement". Moving the helper functions to the
beginning of the surrounding function solves it.

Also make some variables `const`.
2025-07-02 10:29:21 +02:00
Eberhard Beilharz
19d808c6e5
refactor(web): clarify API of KeymanSentryManager
This change marks the functions of `KeymanSentryManager` as public
or private, depending on whether or not they are used outside of the
module.

Test-bot: skip
2025-06-02 18:37:22 +02:00