Commit graph

4544 commits

Author SHA1 Message Date
Marc Durdin
9f71f093cb chore(common): export KmxFileReaderError 2023-06-08 08:51:08 +07:00
Marc Durdin
a1fdc7b133 refactor(developer): CompilerOptions as shared type
Also fixes handling of kmx errors in kmc-package.
2023-06-08 05:42:23 +07:00
Marc Durdin
4c3acaf651 chore(common): update restructure to support typescript 2023-06-08 05:40:48 +07:00
Joshua A. Horton
49788c9364 change(web): double-encoded -> single-encoded 2023-06-07 12:39:37 +07:00
Joshua A. Horton
4fb56e150d chore(web): Merge branch 'feature-esmodule-web-engine' into change/web/filesize-fixes 2023-06-07 12:33:49 +07:00
Joshua A. Horton
bcbe31c7f6 feat(web): adds unit test to catch partial-stub problem early 2023-06-07 09:50:36 +07:00
Steven R. Loomis
ad1d4e734c feat(common): fix bug in build-tran 🙀
For: #7377
2023-06-06 18:37:07 -05:00
Steven R. Loomis
8548b0fd33 Merge remote-tracking branch 'upstream/master' into feat/developer-7377-transform-format-epic-ldml3 2023-06-06 09:45:21 -05:00
Joshua Horton
ed54530d8c
Merge pull request #8895 from keymanapp/feat/web/release-filesize-profiling
feat(web): release-configuration filesize profiling 🧩
2023-06-06 15:22:47 +07:00
Marc Durdin
fdd313a6a2 chore(common): cleanup error handling for KmxFileReader 2023-06-06 15:22:00 +07:00
Joshua A. Horton
718ca50b23 chore(web): Merge branch 'master' into chore/web/feature-esmodule-a17s14-mid-update 2023-06-06 12:37:15 +07:00
Joshua A. Horton
2b0a92725f chore(web): Merge branch 'feature-esmodule-web-engine' into chore/web/loose-ends 2023-06-06 08:56:08 +07:00
Steven R. Loomis
70fcea815a feat(developer): tran support 🙀
- tran builder

For: #7377
2023-06-05 19:18:59 -05:00
Marc Durdin
eaf7a6b628 chore(developer): merge changed interfaces in compiler 2023-06-05 16:34:23 +07:00
Marc Durdin
9d85712039 chore(developer): rollback unneeded kmcomp changes 2023-06-05 16:10:57 +07:00
Marc Durdin
3f993bd651 chore: Merge branch 'master' into feat/typescript-keymanweb-compiler 2023-06-05 15:57:42 +07:00
Joshua A. Horton
a7492957c3 chore(web): Merge branch 'feature-esmodule-web-engine' into chore/web/test-page-patchup 2023-06-05 15:08:36 +07:00
Joshua A. Horton
351cedf25f fix(common/web): fixes Node-worker-reliant input-processor integration tests 2023-06-05 12:19:02 +07:00
Joshua A. Horton
78e86ac9f4 chore(common/models): fixes a formatting nit 2023-06-05 11:44:17 +07:00
Joshua A. Horton
6440eeb4ea docs(common/models): on related package, inability to use Node Blob 2023-06-05 10:15:07 +07:00
Joshua A. Horton
06fa0f0556 change(common/models): replaces 'virtualized' Node worker with actual Node worker 2023-06-05 09:59:31 +07:00
Steven R. Loomis
2054eeb703 feat(developer): tran support 🙀
- support regex format for sets and unicodeSets
- support mapFrom and mapTo detection

For: #7377
2023-06-02 18:31:25 -05:00
Steven R. Loomis
4b81137a61 feat(developer): section dependencies 🙀
- fix test helper for dependencies
- moved VariableParser and MarkerParser into common

For: #7377
2023-06-02 16:58:39 -05:00
Steven R. Loomis
9b177b2f00 feat(developer): section dependencies 🙀
- make explicit section dependencies, add a test

For: #7377
2023-06-02 15:19:00 -05:00
Marc Durdin
0ec5c08b26 chore(common): move const url to class prop
We still have cjs modules that rely on the ldml-keyboard-xml-reader, and
this meant that an exported const was being calculated with an invalid
meta url, which crashed the cjs module require() call.
2023-06-02 12:28:13 +07:00
Marc Durdin
4e535832d8 chore: cleanup 2023-06-02 11:45:59 +07:00
Marc Durdin
a281e1ac60 chore(common): remove redundant path 2023-06-02 11:43:25 +07:00
Marc Durdin
b313272250 chore(common): remove url module ref from common/web/types
The url module is a node module. We need to move responsibility for
resolving the path of the LDML XML <import> statements out of
common/web/types, and into the ultimate consumer, so it's now surfaced
as an option, along with a helper constant that reports the
import.meta.url-relative base path of the standard imports that are
compiled into common/web/types.

This hopefully means we can use this module in both browser and node
contexts without trouble.
2023-06-02 11:38:17 +07:00
Marc Durdin
c3458d040c refactor(developer): move filename consistency check to kmc
kmcmplib no longer has any filesystem access, so it cannot verify if a
referenced filename in a source file has the same case as the actual
filename on disk (a risk when moving projects between platforms). So
I opted to move this to the `loadFile` callback in kmc, which is the
only place where filesystem is actually accessed, and added
corresponding unit test.

Small additional fixes here:

1. Move from `Buffer` to `Uint8Array` in all kmc-* modules, so that we
   remove that barrier to running on web.
2. Use `callbacks.loadFile` instead of `callbacks.fs.readFileSync`, so
   that we can be sure to run the filename consistency check.
3. Fixed kps parser silently swallowing xml errors on load.
4. Added silent mode to NodeCompilerCallbacks so we could cleanly test
   the new filename consistency hint.
5. Noted a location where we still have NodeJS deps in kmc-ldml.
2023-06-01 15:11:38 +07:00
Joshua A. Horton
75058eb623 chore(web): updates per PR review 2023-06-01 15:04:49 +07:00
Joshua A. Horton
c95ba9d94d fix(common/models): missing lm-worker dependencies 2023-06-01 14:53:50 +07:00
Joshua A. Horton
c5f527c204 chore(web): cleans up temp time-profiling code for the lm-worker 2023-06-01 08:54:47 +07:00
Joshua A. Horton
5e668e1567 change(web): worker-embedding via JSON.stringify 2023-06-01 08:48:04 +07:00
Marc Durdin
9d351f4798 chore(developer): verify kvks files and report errors
Fixes #8886.

.kvks compiler now returns helpful errors for xml parse failures and
schema validation errors, and for invalid virtual key codes. Introduces
extra infrastructure for reporting and unit testing messages to kmc-kmn.

This also fixes unhandled xml load exceptions and simplifies the error
reporting coming out of the kvks loader, on the basis that only one type
of error was being reported anyway.
2023-06-01 05:02:26 +07:00
Joshua A. Horton
fa1d7f723c docs(web): better comments in lm-worker build-bundler 2023-05-31 15:54:12 +07:00
Joshua A. Horton
5e93bb0189 feat(web): writes profile logs to file, outputs within new /web/build/profiling folder 2023-05-31 15:51:50 +07:00
Joshua A. Horton
c7be7a1bcb feat(common/models): profile for lm-worker pre-polyfill 2023-05-31 15:27:43 +07:00
Marc Durdin
92278250d5
Merge pull request #8870 from keymanapp/chore/developer/refactor-kmcmplib-interfaces
chore(developer): refactor kmcmplib interfaces
2023-05-31 13:28:30 +10:00
Joshua A. Horton
beafe44a8e chore(web): Merge branch 'chore/web/finish-api-conversion' into chore/web/loose-ends 2023-05-30 14:44:12 +07:00
Joshua A. Horton
464b52e38d chore(web): Merge branch 'change/web/sample-page-rework' into chore/web/test-page-patchup 2023-05-30 12:59:30 +07:00
Marc Durdin
d763cf315a chore(developer): refactor kmcmplib interfaces
Relates to #8493.

* Removes kmcmplib calls from kmcmpdll (now that we have kmc)
* Removes old kmcmp_CompileKeyboardFile and
  kmcmp_CompileKeyboardFileToBuffer functions in preference for a much
  cleaner kmcmp_CompileKeyboard function
* Removes json validation helper from kmcmplib (we'll use js-native
  json schema validation instead)

This change means that we no longer need to keep compfile.h consistent
between kmcmplib and kmcmpdll. This will simplify upcoming refactoring
of kmcmplib.

kmcmplib no longer writes files, but it does still read them. The next
refactor will move file load responsibility into the caller.
2023-05-30 08:14:23 +07:00
Joshua A. Horton
5bd3f962d3 chore(web): Merge branch 'fix/web/browser-toolbar-ui' into fix/web/browser-float-ui 2023-05-29 13:11:35 +07:00
Joshua A. Horton
224d4817ff chore(web): Merge branch 'feature-esmodule-web-engine' into chore/web/prep-feature-gestures-for-rebase-cntd 2023-05-29 11:53:37 +07:00
Joshua A. Horton
6ab5683d2f chore(web): minor build script update 2023-05-29 11:02:06 +07:00
Joshua A. Horton
2387939098 chore(web): dependency version sync 2023-05-29 10:51:42 +07:00
Joshua A. Horton
86c8cb16af chore(web): Merge branch 'master' into feature-gestures-update-a17s14-start 2023-05-29 10:50:34 +07:00
Joshua A. Horton
f0b84adf75 chore(web): Merge branch 'fix/web/dom-keyevent-recorder' into fix/web/integrated-test-restoration 2023-05-29 10:23:10 +07:00
Steven R. Loomis
ca602385b3 feat(developer): vars: hooray for more errors 🙀
For: #7377
2023-05-27 17:01:10 -05:00
Marc Durdin
18c4ac5bb2
Merge pull request #8850 from keymanapp/refactor/developer/wasm-compiler-interface
refactor(developer): compiler interface part 1 for wasm
2023-05-26 18:43:24 +10:00
Joshua A. Horton
60a4a88af3 fix(web): input-processor unit test - param missing 2023-05-26 15:19:19 +07:00