Skip to content

Korean IME input is dropped or corrupted in Markdown preview Cmd+F find box #320869

Closed

Description

@wibaek

Does this issue occur when all extensions are disabled?: Yes

  • VS Code Version: 1.123.2
  • OS Version: macOS 26.4.1 (25E253), arm64

Steps to Reproduce:

  1. Open any Markdown file.
  2. Open the built-in Markdown preview, for example with Markdown: Open Preview to the Side.
  3. Focus the Markdown preview pane.
  4. Press Cmd+F to open the find box for the preview.
  5. Switch to the Korean input method and type Korean text into the find box, for example 안녕하세요 or another Korean search term.

Expected:

The Korean text should be entered into the Markdown preview find box correctly, with all composed characters preserved.

Actual:

Some Korean keystrokes are dropped or entered incorrectly in the Markdown preview find box. The text shown in the find box can differ from what was typed, making it unreliable to search Korean text in Markdown preview.
Image

Notes:

I searched existing issues and PRs before filing this report. I found related Korean/IME/find/webview issues, but I could not find an exact duplicate for Korean IME keystrokes being dropped or misinterpreted specifically in the Markdown preview Cmd+F find box.

I also reproduced the issue with all extensions disabled using code --disable-extensions.

The same behavior was confirmed on a colleague's computer as well, so this does not appear to be specific to my local extension setup or user settings.

Activity

  1. vs-code-engineering commented on Jun 11, 2026

    @vs-code-engineering
    Contributor

    Thanks for creating this issue! It looks like you may be using an old version of VS Code; the latest stable release is 1.124.0. Please try upgrading to the latest version and checking whether this issue remains.

    Happy Coding!

  2. wibaek commented on Jun 11, 2026

    @wibaek
    ContributorAuthor

    This still happens on the latest version, 1.124.0. Thanks!

  3. wibaek commented on Jul 6, 2026

    @wibaek
    ContributorAuthor

    I did some further code analysis and this bug is not specific to the Markdown preview — the root cause is in the shared SimpleFindWidget (src/vs/workbench/contrib/codeEditor/browser/find/simpleFindWidget.ts), whose onInput handler calls focusFindBox() on every input, including the one fired from compositionend in FindInput (src/vs/base/browser/ui/findinput/findInput.ts).
    Korean IME fires compositionend at every syllable boundary, so this blur/refocus cycle aborts the next syllable's composition.

    SimpleFindWidget is used by three widgets, all with checkImeCompletionState: true: WebviewFindWidget (all webview finds, not just Markdown preview), TerminalFindWidget, and the browserView BrowserFindWidget. I have confirmed the same corruption reproduces in the integrated terminal find (Cmd+F in the terminal, typing Korean). Since all three surfaces go through the same shared code path, #320898 fixes it once for all of them.

    Matt Bierner (@mjbvz) could you take a look when you have a chance?

  4. added
    editor-find
    bug
    on Sep 6, 2026
  5. added
    unreleased
    on Sep 6, 2026
  6. added this to the 1.137.0 milestone on Sep 6, 2026
  7. vs-code-engineering commented on Sep 6, 2026

    @vs-code-engineering
    Contributor

    Sharing media and context from merged PR #320898 for verification:

    What changed?
    Updated the shared find input flow so input events fired from compositionend can update search state without immediately restoring focus to the find box (FindInput.onInput now carries { fromCompositionEnd }). Also added a guard so focusFindBox() does not refocus the find input while an IME composition session is still active.

    Why?
    focusFindBox() blurs and refocuses the find input (bouncing through the next-match button). When this runs for the input fired at compositionend — or when an async find result arrives while the next character is already composing — the focus change aborts the active IME composition. Korean IME fires compositionend at every syllable boundary, so characters were dropped or corrupted while typing. The search value is still processed as before; only the focus churn around composition is skipped.

    How I tested this:
    Reproduced the original bug and verified the fix manually with ./scripts/code-web.sh: typing Korean (e.g. 안녕하세요) in the markdown preview find box corrupted characters before this change and is clean after. (Tested on web because webview find is not functional in local desktop builds — stock Electron lacks the findInFrame patch, see #222244.)
    Verified English typing, Enter navigation, and find history behavior are unchanged.
    npm run compile-check-ts-native and ESLint on the changed files pass.

    Before / after
    Before:

    Before.Current.mov

    After:

    After.mov

    Source PR: #320898

  8. added
    insiders-released
    and removed
    unreleased
    on Sep 9, 2026
  9. anthonykim1 commented on Sep 11, 2026

    @anthonykim1
    Contributor

    verified: Image

  10. locked and limited conversation to collaborators on Oct 24, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Labels

bugeditor-findinsiders-releasedverified

Type

No type

Projects

No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions