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

Losing focus on textbox fields #732

Open
Ichigo85 opened this issue Jul 25, 2022 · 3 comments
Open

Losing focus on textbox fields #732

Ichigo85 opened this issue Jul 25, 2022 · 3 comments
Labels
backlog Queued in backlog bug Something isn't working spring cleaning Could be cleaned up one day

Comments

@Ichigo85
Copy link

Ichigo85 commented Jul 25, 2022

Describe the Bug

Hello. I am developing (and/or rewriting) my own properties panel module, specifically for Camunda Modeler but not necessary related to it. I created my own group, which adds specific camunda:Field tags inside the extensionElements tag in various bpmn elements. When i edit one of my textbox fields, the focus on my field is lost, opening the Field Injections group to that new specified field. I should not lose that focus, I don't care if it opens the field injections group for the same field, but I should not lose the focus on my field (losing also what I am writing).

Steps to Reproduce

  1. Implement a small properties provider which creates a text field that creates a new camunda:Field inside some element, just like the bpmn example properties panel for instance
  2. Add a value on this field
  3. The focus for that field is lost, opening the "Field injections" group to the corresponding field Name

Expected Behavior

I should not lose focus on my field, even if it edits a part of the BPMN handled somewhere else. What I am doing is my own personal custom properties provider which not necessarily works with its own moddle.

Environment

  • Host (Browser/Node version), if applicable: Node 16.15.1
  • bpmn-js: 9.3.1
  • bpmn-js-properties-panel: 1.3.0
  • @bpmn-io/properties-panel: 0.16.0

Related to #527

@Ichigo85 Ichigo85 added the bug Something isn't working label Jul 25, 2022
@Ichigo85
Copy link
Author

fieldBug

A gif should better show my bug

@pinussilvestrus
Copy link
Contributor

Hi, thanks for reporting! I think this is similar to this bug which was already reported: #527.

The fact you are adding new fields as a custom extension does not prevent them from being added to the existing Field injections groups. This leads to the behavior that the new field injection got auto-focused.

A workaround here would be to override the field injections group to not display your "custom" entries, or to disable the autofocus behavior at all by setting autoFocusEntry: false.

@pinussilvestrus pinussilvestrus transferred this issue from bpmn-io/properties-panel Jul 25, 2022
@pinussilvestrus
Copy link
Contributor

I moved the issue as I think it fits better to the bpmn-js-properties-panel implementation.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
backlog Queued in backlog bug Something isn't working spring cleaning Could be cleaned up one day
Projects
None yet
Development

No branches or pull requests

2 participants