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

Editor: toolbar buttons break when updating v-model value #6954

Open
FeBe95 opened this issue Dec 12, 2024 · 1 comment
Open

Editor: toolbar buttons break when updating v-model value #6954

FeBe95 opened this issue Dec 12, 2024 · 1 comment
Labels
Resolution: Help Wanted Issue or pull request requires extra help and feedback

Comments

@FeBe95
Copy link

FeBe95 commented Dec 12, 2024

Describe the bug

Now that the broken compatibility of PrimeVue 4.x and Quill 2.0 was resolved (see #5606), another issue is very prominent: When updating the v-model value, some of the toolbar buttons are displayed incorrectly and are left unusable:

  • Before updating v-model:
    grafik
    grafik

  • After updating v-model:
    grafik
    grafik

This is likely being caused by the changes that were made in commit af50c82, back in December 2022.
By looking at the code I suspect the following is happening:

  • Vue is forced to re-render the buttons whenever v-model is updated (by incrementing reRenderColorKey).
  • Quill is not re-initializing the buttons.

This results in the two select elements to be shown, instead of the actual Quill buttons.

Bisect

Reproducer

https://stackblitz.com/edit/primevue-4-vite-issue-template-zqth8o5q?file=src%2FApp.vue

PrimeVue version

4.2.5

Vue version

4.x

Language

ALL

Build / Runtime

Vite

Browser(s)

No response

Steps to reproduce the behavior

  1. Update v-model of Editor
  2. Try to use "text color" or "background color" buttons in Editor toolbar

Expected behavior

Buttons are rendered properly and are working as intended.

@FeBe95 FeBe95 added the Status: Needs Triage Issue will be reviewed by Core Team and a relevant label will be added as soon as possible label Dec 12, 2024
@FeBe95 FeBe95 changed the title Editor: Toolbar Buttons Broken After Updating v-model Value Editor: toolbar buttons break when updating v-model value Dec 12, 2024
@tugcekucukoglu tugcekucukoglu added Resolution: Help Wanted Issue or pull request requires extra help and feedback and removed Status: Needs Triage Issue will be reviewed by Core Team and a relevant label will be added as soon as possible labels Dec 20, 2024
Copy link

Due to PrimeVue team's busy roadmap, this issue is available for anyone to work on. Make sure to reference this issue in your pull request. ✨ Thank you for your contribution! ✨

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Resolution: Help Wanted Issue or pull request requires extra help and feedback
Projects
None yet
Development

No branches or pull requests

2 participants