Skip to content

fix(web): allow to set default keyboard to 'off' - #16524

Open
ermshiperete wants to merge 1 commit into
masterfrom
fix/web/16080_kbdoff
Open

fix(web): allow to set default keyboard to 'off'#16524
ermshiperete wants to merge 1 commit into
masterfrom
fix/web/16080_kbdoff

Conversation

@ermshiperete

@ermshiperete ermshiperete commented Sep 3, 2026

Copy link
Copy Markdown
Contributor

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

@github-project-automation github-project-automation Bot moved this to Todo in Keyman Sep 3, 2026
@keymanapp-test-bot keymanapp-test-bot Bot added the user-test-missing User tests have not yet been defined for the PR label Sep 3, 2026
@keymanapp-test-bot

keymanapp-test-bot Bot commented Sep 3, 2026

Copy link
Copy Markdown

User Test Results

Test specification and instructions

ERROR: user tests have not yet been defined

Test Artifacts

@keymanapp-test-bot keymanapp-test-bot Bot added this to the B19S1 milestone Sep 3, 2026
@ermshiperete
ermshiperete changed the base branch from chore/web/typesInTest to refactor/web/funcscope September 4, 2026 20:32
@ermshiperete
ermshiperete force-pushed the fix/web/16080_kbdoff branch 2 times, most recently from 96c527c to 9de509a Compare September 7, 2026 17:19
}

test.describe.skip('First example from the guide', function () {
test.describe('First example from the guide', function () {

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The guide-examples e2e tests are re-enabled; if it turns out that they're still not stable then we can disable them again.


languageMenu.lgList.style.display='none'; //still allows blank menu momentarily on selection
languageMenu.keyman.contextManager.activateKeyboard(entry.kn, entry.kc,true);
languageMenu.keyman.contextManager.restoreLastActiveTextStore();

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is already done in activateKeyboard, so there's no need to do it twice (especially since activateKeyboard is async, so this call could possibly work with outdated data...)

@ermshiperete
ermshiperete marked this pull request as ready for review September 8, 2026 09:55
Base automatically changed from refactor/web/funcscope to master September 8, 2026 09:56
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
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

fix user-test-missing User tests have not yet been defined for the PR web/

Projects

Status: Todo

Development

Successfully merging this pull request may close these issues.

bug(web): guide-examples.tests.ts appears to have a race bug(web): (re-)allow to set default keyboard to 'off'

1 participant