Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Cursor jumps to end of dcc.Input when pattern is not satisfied #2612

Open
ktul opened this issue Aug 3, 2023 · 0 comments · May be fixed by #2927
Open

Cursor jumps to end of dcc.Input when pattern is not satisfied #2612

ktul opened this issue Aug 3, 2023 · 0 comments · May be fixed by #2927
Labels
bug something broken P3 backlog

Comments

@ktul
Copy link

ktul commented Aug 3, 2023

Describe your context

dash                      2.11.1
dash-ace                  0.2.1
dash-bootstrap-components 1.4.2
dash-core-components      2.0.0
dash-extensions           1.0.3
dash-html-components      2.0.0
dash-table                5.0.0
dash-uploader             0.6.0
- OS: NixOS
- Browser: Firefox
- Version: 95.0.2

Describe the bug

dcc.Input(type="text",
    placeholder="File name",
    className="create_file_input",
    pattern="[a-zA-Z_][a-zA-Z0-9_]*")

Steps to reproduce:

  • Write "abcdef"
  • Insert "$" in the middle -> "abc$def"
  • Pattern is not satisfied -> text cursor jumps to the end behind "f"

Expected behavior

The text cursor should remain at its position after "c".

rodasarede added a commit to rodasarede/dash that referenced this issue Jul 22, 2024
When inserting a non valid character in the middle of a pattern, the cursor instantly jumps to the end of the word, instead of staying in that position.
rodasarede added a commit to rodasarede/dash that referenced this issue Jul 22, 2024
When inserting a non valid character in the middle of a pattern,
the cursor instantly jumps to the end of the word,
instead of staying in that position.
rodasarede added a commit to rodasarede/dash that referenced this issue Jul 22, 2024
When inserting a non valid character in the middle of a pattern,
the cursor instantly jumps to the end of the word,
instead of staying in that position.
Added also some case tests.
@rodasarede rodasarede linked a pull request Jul 22, 2024 that will close this issue
3 tasks
@gvwilson gvwilson self-assigned this Jul 25, 2024
@gvwilson gvwilson removed their assignment Aug 2, 2024
@gvwilson gvwilson added P3 backlog bug something broken labels Aug 13, 2024
@gvwilson gvwilson changed the title [BUG] Cursor jumps to end of dcc.Input when pattern is not satisfied Cursor jumps to end of dcc.Input when pattern is not satisfied Aug 13, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug something broken P3 backlog
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants