Commit graph

580 commits

Author SHA1 Message Date
Marc Durdin
f0fb18a853
Merge pull request #16582 from keymanapp/maint/web/build-perf
maint(web): improve build perf and test params
2026-09-29 11:04:09 +02:00
Marc Durdin
5e710f885c docs(web): deprecate keyman.moveToElement(elem) API
Use instead `elem.focus()`.

Fixes: #16660
Test-bot: skip
2026-09-25 08:19:57 +02:00
Marc Durdin
3c90c732e1 chore(android): remove unused map-polyfill.js and es6-shim.min.js polyfills
These files were copied in but never referenced in 19.0 source.

Fixes: #16583
Test-bot: skip
2026-09-23 11:25:13 +02:00
Joshua Horton
02274223fd fix(android): suppress autocorrection of hardware keystroke input
Fixes: #16602

Build-bot: skip release:web,android
2026-09-18 09:14:59 -05:00
Eberhard Beilharz
7b2f275eb1
Merge pull request #16524 from keymanapp/fix/web/16080_kbdoff
fix(web): allow to set default keyboard to 'off'

The parameters for setKeyboardForControl basically have three different modes: - an id of a keyboard/language to set that keyboard, enabling independent keyboard mode - empty string to set the system keyboard, enabling independent keyboard mode - null to disable independent keyboard mode.

Our previous code didn't properly handle the last two modes. This change fixes the problems and also clarifies and updates the documentation.

Also included is an improvement to the guide-examples e2e tests that now wait until all keyboards are loaded (which may fix #16167).

Partially drafted by kilo.ai.

User tests will follow in an upcoming PR for #16522.

Fixes: #16080
2026-09-17 17:25:24 +02:00
Eberhard Beilharz
56524f1862
Apply batched suggestions from code review
Some checks failed
Keyman Build Summary / Summarize build status checks (push) Has been cancelled
Co-authored-by: Marc Durdin <marc@durdin.net>
2026-09-17 16:50:17 +02:00
Marc Durdin
d850c913b9 maint(web): improve build perf and test params
Allow for additional parameters to mocha (e.g. `-f testname`) and remove
unnecessary build steps; tidy up android-harness build script.

Test-bot: skip
2026-09-17 07:22:46 +02:00
Eberhard Beilharz
4b7c0d48e5
fix(web): address code review comments
Some checks are pending
Keyman Build Summary / Summarize build status checks (push) Waiting to run
2026-09-16 15:37:51 +02:00
Eberhard Beilharz
e50fd2cf7a
chore(web): address code review comments
Also add links to guide examples to test page.
2026-09-11 11:35:40 +02:00
Marc Durdin
fcd34d4cb9
Merge pull request #16531 from keymanapp/fix/web/16503-remove-scroll-to-top
fix(web): remove scroll-to-top on page load
2026-09-10 11:46:37 +07:00
Eberhard Beilharz
4d7867e61c fix(web): allow to set default keyboard to 'off'
Some checks failed
Keyman Build Summary / Summarize build status checks (push) Has been cancelled
The parameters for `setKeyboardForControl` basically have three
different modes:
- an id of a keyboard/language to set that keyboard, enabling independent
  keyboard mode
- empty string to set the system keyboard, enabling independent keyboard
  mode
- `null` to disable independent keyboard mode.

Our previous code didn't properly handle the last two modes. This change
fixes the problems and also clarifies and updates the documentation.

Also included is an improvement to the guide-examples e2e tests that now
wait until all keyboards are loaded (which may fix #16167).

Partially drafted by kilo.ai.

Fixes: #16080
Build-bot: skip release:web
2026-09-08 11:56:41 +02:00
Eberhard Beilharz
04a5cd13c9 chore(web): minor improvements and fixes
Some checks are pending
Keyman Build Summary / Summarize build status checks (push) Waiting to run
Build-bot: skip build:web
Test-bot: skip
2026-09-07 17:05:06 +02:00
Eberhard Beilharz
bd827f8395 refactor(web): clarify function scope and update some function comments 2026-09-07 17:05:06 +02:00
Marc Durdin
22bc09dc8b fix(web): remove scroll-to-top on page load
This is a legacy behaviour from pre KeymanWeb 2.0 days, probably to deal
with buggy rendering in older browsers. Removing as an unwanted
side-effect.

Fixes: #16503
Test-bot: skip
2026-09-04 16:11:05 +02:00
Eberhard Beilharz
7f41b797f2
Merge pull request #16519 from keymanapp/chore/web/constcookie
chore(web): add const for cookie name
2026-09-03 18:24:12 +02:00
Marc Durdin
c64bdb82a6
Merge pull request #16504 from keymanapp/fix/web/16477-remove-deprecated-window-unload-handler
fix(web): remove deprecated `onunload` handler
2026-09-03 21:44:32 +07:00
Eberhard Beilharz
8e4df44aeb
chore(web): add const for cookie name
Build-bot: skip build:web
Test-bot: skip
2026-09-03 14:14:09 +02:00
Eberhard Beilharz
7e6a32cdc7
Merge pull request #16495 from keymanapp/fix/web/16190_KbdNotAvailable
chore(web): tweak error message

Previously the browser component and web engine had the same error message which made it harder to know where the exception happened if a call stack or source map were missing. This change modifies the message in engine.

Related-to: #16190
2026-09-03 11:33:31 +02:00
Eberhard Beilharz
67c7bfe953
chore(web): adjust expected error message in manual test
Some checks are pending
Keyman Build Summary / Summarize build status checks (push) Waiting to run
2026-09-02 15:23:30 +02:00
Eberhard Beilharz
a1d50b35bb
Apply batched suggestions from code review
Co-authored-by: Marc Durdin <marc@durdin.net>
2026-09-02 15:04:40 +02:00
Marc Durdin
405111d815 fix(web): remove deprecated onunload handler
The `onunload` event is deprecated. The only thing we do is cleanup,
which is not necessary if the page is being unloaded anyway.

Fixes: #16477
Test-bot: skip
2026-09-02 10:40:41 +02:00
Eberhard Beilharz
268b64eab5
chore(web): update file headers
Build-bot: skip
Test-bot: skip
2026-09-01 17:57:11 +02:00
Eberhard Beilharz
7a61311147
chore(web): tweak error message
Previously the browser component and web engine had the same error message
which made it harder to know where the exception happened if a call stack
or source map were missing. This change modifies the message in engine.

Related-to: $#16190
Build-bot: skip release:android,ios,web
Test-bot: skip
2026-09-01 17:29:41 +02:00
Keyman Server
90c10d5f34
Merge branch 'epic/autocorrect' into auto/A19S35-merge-base-into-autocorrect 2026-08-14 16:18:38 +02:00
Marc Durdin
1f82507730 docs(web): deprecate unused and obsolete API endpoints and docs cleanup
Deprecate the following obsolete functions and properties:
* `keyman.helpURL`
* `keyman.util.rgba`
* `keyman.util.toFloat`
* `keyman.util.toNumber`
* `keyman.util.toNzString`

Use correct language for code blocks in Keyman Engine for Web
documentation.

Test-bot: skip
2026-08-12 16:07:22 +02:00
Marc Durdin
b40c4b376b fix(web): cleanup loaduserinterface and unloaduserinterface events
The `loaduserinterface` and `unloaduserinterface` events were
incompletely implemented, and the documentation was incomplete. This
change:

1. ensures `loaduserinterface` is called any time a UI is set, either
   during initialization or when the property is set later.
2. ensures `unloaduserinterface` is called immediately before a UI is
   shutdown.
3. updates documentation
4. removes misleading commented code in kmwuifloat.ts

Test-bot: skip
2026-08-12 15:51:55 +02:00
Eberhard Beilharz
e772775461
Merge pull request #16311 from keymanapp/refactor/web/setTargetDir
refactor(web): improve naming of `_SetTargetDir` function

`_SetTargetDir` deals with setting the text direction of the target, not the target directory. This change mainly renames the private function to `setTargetTextDirection`.
2026-08-10 13:53:56 +02:00
Keyman Server
0a868ac7ff
Merge branch 'epic/autocorrect' into auto/A19S34-merge-base-into-autocorrect 2026-08-10 09:54:03 +02:00
Eberhard Beilharz
870903dccb
refactor(web): fix return type of currentKeyboardSrcTextStore
`currentKeyboardSrcTextStore` can return `null` if the global
`textStore` should be used. This change reflects this in the return
type.

Build-bot: skip build:web
Test-bot: skip
2026-08-07 09:37:14 +02:00
Eberhard Beilharz
363f71e9de
refactor(web): improve naming of _SetTargetDir function
`_SetTargetDir` deals with setting the text direction of the target,
not the target directory. This change mainly renames the private function
to `setTargetTextDirection`.

Build-bot: skip build:web
Test-bot: skip
2026-08-07 08:54:22 +02:00
Eberhard Beilharz
21f744f44a
Merge pull request #16286 from keymanapp/refactor/web/contextManager
refactor(web): adjust function visibility and variable names
2026-07-30 15:51:50 +02:00
Eberhard Beilharz
d9f572f92d
refactor(web): adjust function visibility and variable names
Some checks failed
Keyman Build Summary / Summarize build status checks (push) Has been cancelled
The functions are only used inside of the class, so this change makes
them private. Also update some variable names.

Test-bot: skip
2026-07-27 14:17:33 +02:00
Eberhard Beilharz
76058bcc52
chore(web): update help links to use latest version
This updates three in-code help links to point to `current-version`
instead of an outdated version page.

Build-bot: skip
Test-bot: skip
2026-07-27 13:22:04 +02:00
Keyman Server
c2a3fd8d7d
Merge branch 'epic/autocorrect' into auto/A19S33-merge-master-into-autocorrect 2026-07-20 07:26:08 +02:00
Marc Durdin
07daf94555
Merge pull request #16170 from keymanapp/fix/web/16144-define-interfaces-for-imes-in-base
fix(web): define IME interfaces in `KeyboardInterfaceBase`
2026-07-11 00:25:31 +10:00
Marc Durdin
e6d86d7e04 refactor(web): rename keymanweb to keyman in UI modules
The variable name `keymanweb` used in the UI modules is confusing
because `KeymanWeb` also exists and points to something else. Rename to
`keyman` which just mirrors `window.keyman`.

Also fixup type declaration for toolbar `lastDismissalCallback`, which
did not match the assigned type.

Fixes: #16168
Test-bot: skip
2026-07-01 09:18:11 +02:00
Marc Durdin
0fc869faa4 fix(web): define IME interfaces in KeyboardInterfaceBase
Ensure that the IME interface methods are all defined for both browser
and webview modes. Deprecate 'Element' methods and replace with
'TextStore' to clarify return type. Add deprecation flags where needed
and update documentation accordingly.

Fixes: #16144
2026-07-01 07:43:08 +02:00
Marc Durdin
debe12f5d5 chore: Merge branch 'epic/autocorrect' into auto/A19S31-merge-master-into-autocorrect 2026-06-24 16:13:50 +02:00
Joshua Horton
4632f9809e Merge branch 'epic/autocorrect' into auto/A19S30-merge-master-into-autocorrect 2026-06-09 14:50:36 -05:00
Eberhard Beilharz
517e9d26f3
Merge pull request #16064 from keymanapp/chore/web/449_rm_kmw
chore(web): improve the KeymanWeb integration documentation

- replace use of `kmw` with `keyman` 
- unify pattern to load keyboards: do it in `keyman.init().then()` instead   of in the document `onload`

Part-of: keymanapp/keyman.com#449
2026-06-09 18:08:15 +02:00
Eberhard Beilharz
c31cbecce1
Merge pull request #16066 from keymanapp/refactor/web/reformatting
refactor(web): reformatting of files
2026-06-09 14:38:32 +02:00
Eberhard Beilharz
c1113ac21d
chore(web): address code review comments
Some checks failed
Keyman Build Summary / Summarize build status checks (push) Has been cancelled
Also change a few places that I missed.
2026-06-08 19:27:12 +02:00
Eberhard Beilharz
57a0d63e47
refactor(web): address code review comments
Some checks failed
Keyman Build Summary / Summarize build status checks (push) Has been cancelled
2026-06-08 17:47:45 +02:00
Eberhard Beilharz
f218aa92db
refactor(web): reformatting of files
Test-bot: skip
2026-06-03 19:51:44 +02:00
Eberhard Beilharz
43398df243
refactor(web): extract function, rename variables
Test-bot: skip
2026-06-03 18:40:18 +02:00
Eberhard Beilharz
a7b9d5da5a
fix(web): fix displaying of keyboard menu
The recent partial merge of epic/web-core missed some code that causes
the keyboard menu to work. This change re-applies those changes.

Test-bot: skip
2026-06-02 18:29:03 +02:00
Eberhard Beilharz
e21f2020d0
Merge pull request #16042 from keymanapp/fix/web/16041_displaymenu
fix(web): fix race displaying active keyboard in menu
2026-06-02 15:28:19 +02:00
Eberhard Beilharz
f827936362
fix(web): fix race in kmwuifloat.ts as well 2026-06-02 12:15:12 +02:00
Eberhard Beilharz
3cb59e3cf9
fix(web): fix race displaying active keyboard in menu
Fixes: #16041
Build-bot: skip release:web
Test-bot: skip
2026-06-01 17:51:42 +02:00
Marc Durdin
439bdce6b5
Merge branch 'chore/web-core-preflight' into chore/web-core-strip-core 2026-06-02 00:52:28 +10:00