q-btn stack
prop weird behavior on undefined
#16494
Labels
area/components
bug/1-repro-available
A reproduction is available and needs to be confirmed.
flavour/quasar-cli-vite
kind/bug 🐞
Qv2 🔝
Quasar v2 issues
What happened?
Created a CustomButton wrapping q-btn and run into a minor styling issue that i thought it was unintentional. So basically i had a condition for the
stack
prop.Where
customStack
was defined like any custom-like boolean prop would:Actual behavior:
When the condition is met the button stacks vertically, but when not provided, margin between the icon and the label are removed.
stack
isundefined
What did you expect to happen?
Expected behavior:
The q-btn label with its icon would conditionally stack vertically.
stack
istrue
stack
isfalse
Documentation clearly states that
stack
is of typeBoolean
and notBoolean | undefined
, but i believed this was maybe unintentional?Reproduction URL
https://codepen.io/dtsiantaris/pen/VwgwwNv
How to reproduce?
Flavour
Quasar CLI with Vite (@quasar/cli | @quasar/app-vite)
Areas
Components (quasar)
Platforms/Browsers
Firefox, Chrome, Microsoft Edge
Quasar info output
No response
Relevant log output
No response
Additional context
I know that the fix is as simple as this:
But i say again, i believe this was unintentional from the Quasar team.
The text was updated successfully, but these errors were encountered: