Closed nicksellen closed 2 years ago
Sorry but I cannot reproduce it on Firefox 103.0 (64 bit) on Ubuntu.
Here's a video of it failing just using the codepen:
https://user-images.githubusercontent.com/31616/186700798-1ebad663-3eb4-457f-8ec3-d0bca2c39b72.mp4
I'm on firefox 104.0 64bit on arch linux
Do you want me to try something else?
I think it would work just changing the ordering of inp.style.overflow = 'hidden'
.. but can't try that out easily in the codepen.
@pdanpdan I can confirm that this bug is only present in v104. I have had a client that reported the problem to me. I was using FF v103 and updated to v104 and it's indeed broken. It is specific to FF v104. Testing it in Chrome-based browser works fine.
I'm seeing this on FF 104 as well.
Quasar v1 is also affected (currently on 1.19.3) - only after update to Firefox v104. Works in Chrome.
Quasar v1.19.4 and v1.19.5 also affected in FF 104 (104.0.2 if that makes any difference). Chrome fine.
Fix will be available in v2.8.3
Will the fix be backported to Quasar v1?
Yes, in next release
What happened?
I noticed sometimes my autogrow QInputs were not autogrowing, and would actually have the text half the height it should be (so it was chopped through the middle):
This is where we are using the QInput:
https://github.com/karrot-dev/karrot-frontend/blob/3e277783317dbd28ebd265da3f94d22a9817ca26/src/utils/components/MarkdownInput.vue#L7-L16
$attrs['input-style']
is set asmin-height: unset; max-height: 320px;
in this particular case.https://github.com/karrot-dev/karrot-frontend/blob/3e277783317dbd28ebd265da3f94d22a9817ca26/src/messages/components/ConversationCompose.vue#L28
What did you expect to happen?
The auto grow should work and it should not be chopped off...
Reproduction URL
https://codepen.io/nicksellen-the-decoder/pen/jOzoWgX
How to reproduce?
Flavour
Quasar CLI with Webpack (@quasar/cli | @quasar/app-webpack)
Areas
Components (quasar)
Platforms/Browsers
Firefox
Quasar info output
Relevant log output
No response
Additional context
It was introduced in this PR https://github.com/quasarframework/quasar/pull/13237
I think there two possible solutions:
1. always set
overflow: hidden
on the input when using autogrowusing
input-style="input: hidden;"
works for me locally and in the pen, maybe it can be set inside QInput component2. change the ordering of the calls
I tried editing the quasar source locally, and in my application the issue was resolved by switching the order, so the call to set overflow hidden is done first, from:
https://github.com/quasarframework/quasar/blob/078698cc3c3beaed2222392fc6492c4cea369e45/ui/src/components/input/QInput.js#L299-L301
to:
In my exploring I also noticed the issue was resolved when I put a
console.log
line in various places in that bit of code, and it didn't occur when the whole browser window could scroll... so I think there is a subtle timing issue in firefox with the browser redrawing/recalculating the scrollHeight...I was consistently getting a height set of 15px, even when the scrollHeight was more when I logged it...