-
-
Notifications
You must be signed in to change notification settings - Fork 3.7k
QKnob with image content in default slot can't be interacted with to update model value #17812
Copy link
Copy link
Closed
Labels
Qv2 🔝Quasar v2 issuesQuasar v2 issuesarea/componentsbug/0-needs-infoNeed more info to reproduceNeed more info to reproduceflavour/quasar-cli-vitekind/bug 🐞
Description
What happened?
mousing over a Knob component with an image in the default slot results in the browser's default image dragging behavior to override the QKnobs behavior:
from: https://quasar.dev/vue-components/knob#example--show-value
<q-knob
show-value
font-size="10px"
class="q-ma-md"
v-model="value"
size="80px"
:thickness="0.25"
color="primary"
track-color="grey-3"
>
<q-avatar size="60px">
<img src="https://cdn.quasar.dev/logo-v2/svg/logo.svg">
</q-avatar>
</q-knob>Screen.Recording.2025-02-07.at.8.43.16.AM.mov
Adding pointer-events: none to the slot's containing element resolves the problem:
Screen.Recording.2025-02-07.at.8.41.28.AM.mov
What did you expect to happen?
I expected to be able to click and drag on the knob, changing the value.
Reproduction URL
https://codepen.io/euphemism-the-encoder/full/zxOgpbV
How to reproduce?
- Go to link
- Click and drag on knob (Quasar logo image in center)
- Observe browser-native image dragging behavior instead of model change
Flavour
Quasar CLI with Vite (@quasar/cli | @quasar/app-vite)
Areas
Components (quasar)
Platforms/Browsers
Firefox, Safari, iOS, Chrome
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
Qv2 🔝Quasar v2 issuesQuasar v2 issuesarea/componentsbug/0-needs-infoNeed more info to reproduceNeed more info to reproduceflavour/quasar-cli-vitekind/bug 🐞