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

Usign :lazy="false" does not work propelry with VueDatePicker #77

Open
lealea401 opened this issue Jun 9, 2023 · 1 comment
Open

Usign :lazy="false" does not work propelry with VueDatePicker #77

lealea401 opened this issue Jun 9, 2023 · 1 comment

Comments

@lealea401
Copy link

I am trying to drag the slider in order to update the date in the VueDatePicker calendar while dragging.
I am using "@vuepic/vue-datepicker": "^5.2.0" and "@vueform/slider": "^2.1.7",
If I use lazy false I can drag one step, but then the functionallity stops and I then I need to drag again.
If I use "@vueform/slider": "^1.0.5" it works more or less but the dragging is not smooth along the slider. It has some delay.
Could there be a solution for it? Is there any incompatibility between the two components?

@dib258
Copy link

dib258 commented Jun 29, 2023

I think I have the same problem but I'm not using @vuepic/vue-datepicker

Juste @vueform/slider and when I drag the slider and updating the model value in the parent via an emit.

I loose the focus on the slider and need to re-click and drag. I can only change by 1 unit (with a step of 1)

Could this be happening because :

  • we drag,
  • modify the value
  • emit to parent
  • the parent give the new value to the child component (the slider)
  • and the slider loose focus because of the change of the value?

Seems weird but maybe it's an explanation.

After some more digging, it seems that this behavior happens when two events are used together.

Like @update and @end
or @change and @update
or @slide and @change

Is it bad practice to use two ?

For example when I'm dragging on a tablet/phone the tooltip doesn't show, so I wanted to update the model to show the user somewhere else the result of the dragging. While I want to make a call to the server when the user release the drag.

Thanks if anyone find a way to make this work ! :)

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

No branches or pull requests

2 participants