Commit graph

102 commits

Author SHA1 Message Date
Marc Durdin
df212364a2 maint(resources): add repository record for all published packages
While not documented as such, it appears that the repository record is
required with trusted publishing of npm packages.

Test-bot: skip
Build-bot: skip
2025-10-29 14:35:31 +01:00
Marc Durdin
58b56f7ed1
Revert "chore(deps-dev): bump playwright from 1.46.1 to 1.56.1" 2025-10-23 11:02:53 +02:00
dependabot[bot]
006f0a57cf
chore(deps-dev): bump playwright from 1.46.1 to 1.56.1
Bumps [playwright](https://github.com/microsoft/playwright) from 1.46.1 to 1.56.1.
- [Release notes](https://github.com/microsoft/playwright/releases)
- [Commits](https://github.com/microsoft/playwright/compare/v1.46.1...v1.56.1)

---
updated-dependencies:
- dependency-name: playwright
  dependency-version: 1.56.1
  dependency-type: direct:development
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-10-20 18:55:50 +00: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
Joshua Horton
8991df3865 maint: update fast-json-parser
The `fast-json-parser` package is needed by `ajv-cli`, which is used during common/web/types/build.sh configure.

Test-bot: skip
2025-05-13 14:46:32 +07:00
Joshua Horton
155c1a2b12 maint: update mocha
Some of the npm audit warnings left after #13897 require an updated `mocha` version to remedy.  As we only really use `mocha` to do unit-testing, it should be safe to update if all of our existing tests pass with the new version.

Test-bot: skip
2025-05-13 14:02:02 +07:00
dependabot[bot]
4abc1b3d2b
chore(deps-dev): bump esbuild from 0.18.20 to 0.25.0
Bumps [esbuild](https://github.com/evanw/esbuild) from 0.18.20 to 0.25.0.
- [Release notes](https://github.com/evanw/esbuild/releases)
- [Changelog](https://github.com/evanw/esbuild/blob/main/CHANGELOG-2023.md)
- [Commits](https://github.com/evanw/esbuild/compare/v0.18.20...v0.25.0)

---
updated-dependencies:
- dependency-name: esbuild
  dependency-type: direct:development
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-02-11 11:17:53 +00:00
Marc Durdin
50097802ba chore: include sourcemap-path-remapper tool in package.json 2025-01-27 10:22:28 +07:00
Marc Durdin
75d77704a2 refactor: move langtags to @keymanapp/langtags npm module
We want to use langtags in several modules, so it makes sense to make it
into its own NPM module.

Relates-to: #13045
2025-01-27 09:59:38 +07:00
Marc Durdin
7d17913e18 feat(developer): seed kmc-copy 2024-10-22 10:28:00 +07:00
Marc Durdin
0d9688451d
Merge branch 'master' into feat/developer/kmc-generate 2024-10-11 03:26:54 +02:00
Marc Durdin
640d3e5096 test(developer): add markdown link check test for product documentation
Adds check-markdown package that parses .md files, looks for links and
images, and verifies that they are valid links (for internal links).
2024-09-25 15:51:32 -07:00
Marc Durdin
8424cb9349
Merge branch 'master' into feat/developer/kmc-generate 2024-09-12 08:18:37 +02:00
Eberhard Beilharz
a9b9c4d016
refactor(web): move common/models to web/src/engine/predictive-text
Fixes: #12133
2024-09-10 17:45:22 +02:00
Marc Durdin
939134a9a3 feat(developer): kmc-generate module
Plenty of todo items left but this is a mostly-functional module for the
kmc generate command for automatically creating keyboard and model
projects.
2024-09-03 06:15:33 +07:00
Eberhard Beilharz
e788bf5077
fix(web): enable tests to run on Ubuntu 24.04 Noble
Previously running the tests failed because it couldn't find ICU 70 when
running webkit. Ubuntu 24.04 Noble comes with ICU 74. Updating
playwright to 1.46 fixes this.
2024-08-26 16:22:15 +07:00
Eberhard Beilharz
7dabd30cae
refactor(web): move gesture-recognizergesture-processor
Moves `common/web/gesture-recognizer/` →
`web/src/engine/osk/gesture-processor`.

Fixes: #12151
2024-08-26 15:29:21 +07:00
Eberhard Beilharz
b9aa9ccd8c
refactor(web): move predictive-textworker-main
This moves `common/predictive-text/` →
`web/src/engine/predictive-text/worker-main/`.

This also moves `common/test/predictive-text/` →
`web/src/test/manual/predictive-text/`. Note though that this testing
tool is still broken.

Fixes: #12134
2024-08-15 12:26:50 +02:00
Marc Durdin
37a168ec1a chore(common): back to node 20.16.0
node 22.5.1 (or its corresponding npm version) breaks optional dependencies in
developer/server, so node-windows-trayicon is never installed. Needs investigation
and resolution before we move to that version, so conservatively moving back to
current LTS.
2024-08-01 06:19:02 +07:00
Marc Durdin
12ee391895 chore(common): use node v22.5.1 2024-08-01 05:10:41 +07:00
Marc Durdin
db904b5617 fix(developer): cleanup package.json and build.sh errant references
During analysis of root causes for #12027, discovered a few package
relationship issues in package.json and build.sh.

analyzer-messages.ts ///<reference> is a mitigation for now.

Relates-to: #12027
2024-07-26 06:57:32 +07:00
Steven R. Loomis
dcead98f3e chore(common): deps: update eslint typescript plugins
- replace eslint-config-standard-with-typescript with eslint-config-love (author's recommendation)
- bump to @typescript-eslint/eslint-plugin@7.13.1 which supports Typescript 5.4.x
2024-06-20 16:50:01 -05:00
Marc Durdin
14eeb00405
Revert "chore(common): update base-package node-engine setting" 2024-06-19 15:14:19 +10:00
Joshua A. Horton
6b565cad93 change(common): set package to node 22 only 2024-06-17 15:11:57 +07:00
Joshua A. Horton
d57022cdc7 change(common): sets a minimum v20 b/c import attributes 2024-06-17 11:51:57 +07:00
Joshua A. Horton
1e13272d1b chore(common): update base-package node-engine setting
Fixes: #11689
2024-06-17 11:45:37 +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 A. Horton
b682f896ec change(common): match original version from package-lock 2024-06-10 11:43:23 +07:00
Joshua A. Horton
99ef7a8dec chore(common): restore source-map-support package
It's in use in a number of mocha "register" configs but was only ever installed b/c ts-node had it as a dependency.
2024-06-10 11:40:59 +07:00
Joshua A. Horton
1e757c0821 chore(common): fully removes ts-node
Fixes: #11736
2024-06-10 11:06:13 +07:00
Joshua A. Horton
cb0a60165c change(common): updates esbuild to 0.18.9 2024-06-05 12:09:53 +07:00
Joshua A. Horton
01fa0675ef chore(web): centralizes on a single @types/node, as it caused a TS typing conflict 2024-05-15 16:00:35 +07:00
Joshua A. Horton
70d06d7cd1 chore(web): updates all KMW-related projects to TS 5.4.5 2024-05-15 16:00:34 +07:00
Joshua A. Horton
8d7721545a chore(web): updates sinon to a version with fully-ESM artifact 2024-05-09 08:49:51 +07:00
Joshua A. Horton
dd87a65f49 chore(web): adds test-runner esbuild plugin package 2024-05-07 14:50:53 +07:00
Joshua A. Horton
48db58c82e chore(web): adds '@web/test-runner' and related packages 2024-05-07 14:42:39 +07:00
Joshua A. Horton
ec35fbb061 chore(web): @types/node update - version should match node version
Also updates @types/chai, given that chai was updated.  No ^5.x yet, though.
2024-05-07 14:38:40 +07:00
Joshua A. Horton
5574b9418f chore(web): chai dependency updates
Updates 'chai' assertion library to latest; old version used CommonJS imports
2024-05-07 14:35:08 +07:00
Marc Durdin
db514e0dc5 fix(common): update emoji stripping for Unicode 15.1
Fixes #11220.

Replaces the sed script for matching emoji in ios prepRelease with a
tiny node project that uses emoji-regex package, to reduce future
maintenance.

Also strips lingering emoji and :xxx: emoji shortcut strings from
HISTORY.md. Note that :xxx: are not stripped programatically at this
time.
2024-04-18 09:05:30 +07:00
Marc Durdin
661069c0c3 feat(developer): add api-extractor and api-documenter and config
Relates to #10207.

Adds @microsoft/api-extractor and @microsoft/api-documenter NPM
packages for validating and generating API documentation from Typescript
modules.

Adds basic configuration for each module that we will be publishing at
this time.

api-extractor's output will be emitted to /developer/docs/api/etc/, for
future release comparisons. A baseline output will be committed
separately.

The build outputs will be in /developer/build/docs and the intermediate
files will be in /developer/build/api.

Note that at this time, we will not enable the checks and validations.
That is a task for alpha rather than beta. The primary intent at this
time is to select a solid, well-supported toolchain for generating the
API documentation for kmc.
2024-02-26 11:37:32 +07:00
Marc Durdin
662ed0e50c fix(common): publish @keymanapp/developer-utils as npm module
Fixes #10111.
2023-12-01 14:05:51 +07:00
Marc Durdin
225877f57a feat(common): precompile json schemas to improve performance
Fixes #9640.

This ended up being somewhat more fragile than originally anticipated.
For the `ajv` cli call to get the right versions, we needed to install
ajv as a dev dependency in the top-level package.json as well as at the
common/web/types level.

Ajv does not do all that well with ESM yet, either, so we use esbuild to
transform the compiled validators before building in typescript.
2023-10-05 13:56:53 +07:00
Marc Durdin
7f76de4781 chore(developer): add developer-utils as workspace 2023-09-01 10:11:15 +07:00
Marc Durdin
232c918c31 feat(developer): support isRTL and license fields in .model_info
Adds support for calculating isRTL and license fields in .model_info
compiler.

Also:
* establishes @keymanapp/developer-utils shared module
* moves license validation into @keymanapp/developer-utils
* refactors kmc-model-info to a class and general cleanup
2023-08-29 16:37:37 +10:00
Marc Durdin
fa19eea873 chore(developer): improve kmc sentry reporting on fatal build errors
kmc already reported unhandled exceptions, but any handled fatal errors
were captured and only reported to the user. It is better to report
these to Sentry as these are still unexpected.

I have refactored all the fatal exception messages in various kmc
modules to use a common mechanism, keeping all the Sentry integration in
kmc, now passing exception data up in the `CompilerEvent.exceptionVar`
property.

* I took the opportunity to rename messages.ts to
  infrastructureMessages.ts

* @types/chai was missing which gave intellisense errors in vscode

* normal exit of kmc now provides an opportunity for error reports to
  Sentry to be finalized

* Added a unit test for fatal errors in kmc

* Added a manual test pathway with `SENTRY_CLIENT_TEST_BUILD_EXCEPTION`
  env var to trip the build fatal error mechanism and verify that it
  looks ok; the following shows test runs demonstrate how fatal build
  errors are reported:

```
mcdurdin@THARK MINGW64 /c/Projects/keyman/app/developer/src/kmc (chore/developer/report-fatal-compiler-errors-to-sentry)
$ SENTRY_CLIENT_TEST_BUILD_EXCEPTION=1 node . --error-reporting build
fatal KM05001: Unexpected exception: Error: Test exception from SENTRY_CLIENT_TEST_BUILD_EXCEPTION

Call stack:
Error: Test exception from SENTRY_CLIENT_TEST_BUILD_EXCEPTION
    at build (file:///C:/Projects/keyman/app/developer/src/kmc/build/src/commands/build.js:78:19)
    at Command.<anonymous> (file:///C:/Projects/keyman/app/developer/src/kmc/build/src/commands/build.js:66:24)
    at Command.listener [as _actionHandler] (C:\Projects\keyman\app\node_modules\commander\lib\command.js:482:17)
    at C:\Projects\keyman\app\node_modules\commander\lib\command.js:1283:65
    at Command._chainOrCall (C:\Projects\keyman\app\node_modules\commander\lib\command.js:1177:12)
    at Command._parseCommand (C:\Projects\keyman\app\node_modules\commander\lib\command.js:1283:27)
    at C:\Projects\keyman\app\node_modules\commander\lib\command.js:1081:27
    at Command._chainOrCall (C:\Projects\keyman\app\node_modules\commander\lib\command.js:1177:12)
    at Command._dispatchSubcommand (C:\Projects\keyman\app\node_modules\commander\lib\command.js:1077:23)
    at Command._parseCommand (C:\Projects\keyman\app\node_modules\commander\lib\command.js:1248:19)

    This error has been automatically reported to the Keyman team.
      Identifier:  6f0fca1a26694c22b03f02b2463d39c5
      Application: Keyman Developer
      Reported at: https://sentry.io/organizations/keyman/projects/keyman-developer/events/6f0fca1a26694c22b03f02b2463d39c5/

mcdurdin@THARK MINGW64 /c/Projects/keyman/app/developer/src/kmc (chore/developer/report-fatal-compiler-errors-to-sentry)
$ SENTRY_CLIENT_TEST_BUILD_EXCEPTION=1 node . --no-error-reporting build
fatal KM05001: Unexpected exception: Error: Test exception from SENTRY_CLIENT_TEST_BUILD_EXCEPTION

Call stack:
Error: Test exception from SENTRY_CLIENT_TEST_BUILD_EXCEPTION
    at build (file:///C:/Projects/keyman/app/developer/src/kmc/build/src/commands/build.js:78:19)
    at Command.<anonymous> (file:///C:/Projects/keyman/app/developer/src/kmc/build/src/commands/build.js:66:24)
    at Command.listener [as _actionHandler] (C:\Projects\keyman\app\node_modules\commander\lib\command.js:482:17)
    at C:\Projects\keyman\app\node_modules\commander\lib\command.js:1283:65
    at Command._chainOrCall (C:\Projects\keyman\app\node_modules\commander\lib\command.js:1177:12)
    at Command._parseCommand (C:\Projects\keyman\app\node_modules\commander\lib\command.js:1283:27)
    at C:\Projects\keyman\app\node_modules\commander\lib\command.js:1081:27
    at Command._chainOrCall (C:\Projects\keyman\app\node_modules\commander\lib\command.js:1177:12)
    at Command._dispatchSubcommand (C:\Projects\keyman\app\node_modules\commander\lib\command.js:1077:23)
    at Command._parseCommand (C:\Projects\keyman\app\node_modules\commander\lib\command.js:1248:19)
```
2023-08-09 09:34:44 +07:00
Marc Durdin
c9e1e82a76
Merge branch 'feature-kmc-kmw' into feat/developer/introduce-kmc-keyboard-info 2023-07-26 19:24:34 +10:00
Marc Durdin
3cc0f37e1b feat(developer): introduce kmc-keyboard-info
Adds kmc-keyboard-info module and a basic unit test for it. Integration
into kmc is next step.
2023-07-24 10:41:12 +07:00
Marc Durdin
1810434b34 chore: Merge branch 'feature-kmc-kmw' into chore/merge-master-into-kmc-kmw-a17s17 2023-07-21 10:09:33 +07:00
Steven R. Loomis
50f0b3112a Merge remote-tracking branch 'upstream/master' into chore/common-8950-node18-engine 2023-07-04 15:51:37 -05:00
Marc Durdin
d914b6918d chore: Merge branch 'feature-kmc-kmw' into chore/merge-master-into-feature-kmc-kmw-a17s16-start 2023-06-26 14:33:20 +07:00