[Solved] [V1] QInput property "upper-case" is missing
-
Hi Quasar team,
Could you please check it?
Best Regards,
Stanley -
@Stanley you can use css helpers https://quasar.dev/style/typography#CSS-Helper-Classes or mask https://quasar.dev/vue-components/input#Mask. Check upgrade guide too if youre migrating from old quasar version https://quasar.dev/start/upgrade-guide#QInput.
-
@metalsadman Yes, it works now. Thanks!
-
@metalsadman I just found another issue, it only changes the display format. However, I would like to change the internal format as well.
For example, I input something like aaaBBB, it displays as AAABBB, however, the internal format is still aaaBBB. I would like to change it to uppercase AAABBB.
Do you have any suggestion, thanks! -
@Stanley
<q-input filled v-model="id" label="Special ID" mask="A" reverse-fill-mask ></q-input>
ormask="X"
for alphanumeric. https://codepen.io/metalsadman/pen/ZdKjqj?editors=1011 -
@metalsadman Thanks for your quick response. But I am afraid it still does not meet my requirement. In your case, it can not input symbols. I would like to input anything and convert letters to uppercase. Can we do it?
-
@Stanley yeah just ignore all those and use javascript String toUpperCase
<q-input @input="val => { yourModel = val.toUpperCase() }" .... />
. updated the pen https://codepen.io/metalsadman/pen/ZdKjqj?editors=1011. -
@metalsadman Yes, it can be a workaround. By the way, could you please add this requirement in the future release, then I can wait for the next release.
-
you could post it as feature request, tho you can just extend q-input and add this functionality your self.
-
@metalsadman Thanks for your help!