q-tab click event handler has no 'go' argument anymore #16186
Replies: 2 comments
-
Hi @jumpapex! 👋 It looks like you provided an invalid or unsupported reproduction URL. Without a proper reproduction, your issue will have to get closed. Thank you for your collaboration. 👏 |
Beta Was this translation helpful? Give feedback.
-
in the docs @click event is only for QRouteTab, if you want to control navigation use QTabs |
Beta Was this translation helpful? Give feedback.
-
What happened?
we have used q-tabs, q-tab and q-tab-panels to implement something like property pages.
Also we handle q-tab @click event to do some validatation before switch tab panel.
It works well with quasar 2.7.1, but not work with 2.12.3
Finally, I have found that version 2.12.3 has changed the logic, it just update the tab model anyway and will not call click with 'go' argument.
What did you expect to happen?
q-tab click event handler should not update the tab model if e.defaultPrevented is set to true and has 'go' argument.
or
is there any workaround for it(I don't want to use q-route-tab:))
Reproduction URL
https://codepen.io/tangram7/pen/PoxgRMO?editors=1011
How to reproduce?
From the URL,
click "MAIL" tab, should switch to it(but console log 'go' is undefined, and q-tabs switch the tab anyway).
click "ALARM" tab, should not switch to it.
click "MOVIES" tab, should switch to it(but console log 'go' is undefined, and q-tabs switch the tab anyway).
Flavour
Quasar CLI with Vite (@quasar/cli | @quasar/app-vite)
Areas
Components (quasar)
Platforms/Browsers
No response
Quasar info output
No response
Relevant log output
No response
Additional context
No response
Beta Was this translation helpful? Give feedback.
All reactions