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

fix: fire change event on hyperlink edit, update test timings #7250

Merged
merged 1 commit into from Mar 21, 2024

Conversation

web-padawan
Copy link
Member

Description

Fixes #7249

When adding link, the change event was not fired by vaadin-rich-text-editor. Here's what happened:

  • editor gets focus as a result of this._editor.format('link', link, SOURCE.USER),
  • the editor content focus event listener calls _cleanToolbarState() immediately,
  • in value change observer, no change event due to the toolbar in "default" state.

Added a check for _linkEditing (which corresponds to the link dialog opened property) as a fix.

Note: when removing the focus listener completely, all the tests still pass on main branch 🙈

Type of change

  • Bugfix

Copy link

sonarcloud bot commented Mar 21, 2024

Quality Gate Passed Quality Gate passed

Issues
0 New issues
0 Accepted issues

Measures
0 Security Hotspots
No data about Coverage
0.0% Duplication on New Code

See analysis details on SonarCloud

@web-padawan web-padawan merged commit 9c24c1d into main Mar 21, 2024
9 checks passed
@web-padawan web-padawan deleted the fix/rte-link-change branch March 21, 2024 10:50
@vaadin-bot
Copy link
Collaborator

Hi @web-padawan and @web-padawan, when i performed cherry-pick to this commit to 23.4, i have encountered the following issue. Can you take a look and pick it manually?
Error Message:
Error: Command failed: git cherry-pick 9c24c1d
error: could not apply 9c24c1d... fix: fire change event on hyperlink edit, update test timings (#7250)
hint: After resolving the conflicts, mark them with
hint: "git add/rm ", then run
hint: "git cherry-pick --continue".
hint: You can instead skip this commit with "git cherry-pick --skip".
hint: To abort and get back to the state before "git cherry-pick",
hint: run "git cherry-pick --abort".

@vaadin-bot
Copy link
Collaborator

This ticket/PR has been released with Vaadin 24.4.0.alpha17 and is also targeting the upcoming stable 24.4.0 version.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[rich-text-editor] Incorrect test checking for change event on link confirm
3 participants