Skip to content

plugin-search: Pressing the Enter key to finalize the converted text will cause a unintended page transition #2850

Open
@piyoppi

Description

@piyoppi
  • I confirm that this is an issue rather than a question.

Bug report

When typing a text in the search box and pressing Enter to convert it, the active suggestion is selected, causing an unintended page transition.
(In Japanese input, we often use the Enter key to confirm a character conversion.)

This issue was occered in a MacOS browsers (Chrome, Firefox). It was not reproduced in Windows OS.

Steps to reproduce

I add markdown file written in Japanese. https://github.com/piyoppi/vuepress/tree/demo-plugin-search-with-ime/packages/docs/docs/demo-for-japanese-input

It is including in the following branch. You can reproduce it by entering Japanese text (e.g. "タイトル") in the search box.

https://github.com/piyoppi/vuepress/tree/demo-plugin-search-with-ime

What is expected?

vuepress-expected

Pressing the Enter key to finalize the converted text will not cause a page transition.

What is actually happening?

vuepress-actual

Pressing the Enter key to finalize the converted text will cause a page transition.

Other relevant information

  • Output of npx vuepress info in my VuePress project:

Activity

piyoppi

piyoppi commented on May 12, 2021

@piyoppi
Author

I tried to fix the issue using Implicit submission of Form.

piyoppi@89f26c6

I am going to submit a pull request.

added a commit that references this issue on May 12, 2021
346d896
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

      Participants

      @piyoppi

      Issue actions

        plugin-search: Pressing the Enter key to finalize the converted text will cause a unintended page transition · Issue #2850 · vuejs/vuepress