Hide the priority_high in QInput on error
-
How would I go about hiding the exclamation mark ?
[v1-beta]
-
Try this css:
.q-field--error .q-icon { visibility: hidden; }
Scott
-
Added “no-error-icon” Boolean prop. Will be available in beta.15
-
@rstoenescu Thank you !
-
@s-molinari Thank you but that would hide all icons. So it will only work if you have no other icons used.
-
@turigeza - does it? Add text to the field too.
https://codepen.io/smolinari/pen/YMPjvx
@rstoenescu - maybe just add a
warning-icon
prop and let the devland dev decide if they want an icon for the warning at all and which icon? If nothing is defined in the prop, then nothing is shown?Scott
-
@s-molinari
Thank you!It seems there is a difference in behaviour if you set the error yourself instead of the validation rules.
https://codepen.io/turigeza/pen/eoNMKwI am talking nonsense sorry … There is no difference in behaviour. All icons will be hidden on error
https://codepen.io/turigeza/pen/QPbryP@rstoenescu I like s-molinari suggestion if you are making the effort to change it and it’s not much more work. Mind for me these icons are not important … I will be hiding them most of the time.
-
Yeah. Nevermind. Don’t know what I was thinking.
Scott
-
We want to follow Material Guidelines as strictly as possible, and I see the error icon there by default. So a
no-error-icon
makes a bit more sense… -
@rstoenescu I am fine with that. Also an option to add a class to it so I can target it with css and hide it. I leave it with you. Thank you for implementing it.
-
The Material spec says this:
- Icons
Icons can be used to message alerts as well. Pair them with error messages to provide redundant alerts, which are useful when you need to design for colorblind users.
Nothing specific about which icon.
In the end, it doesn’t really matter to me. I’m just thinking, where a framework doesn’t need to be opinionated, it shouldn’t be.
In fact, the icon used in the spec is different than the one used in Quasar.
Just sayin!
Scott
- Icons
-
They keep changing Material Design specs weekly. Updated icon in beta.15 (released).
But like you read: “Icons […] are useful when you need to design for colorblind users” --> since Quasar is a framework, it must adhere to best practices -
Absolutely.
I also just remembered, the devland dev can define a different icon too. So, nevermind.
https://codepen.io/smolinari/pen/WWQybN
Scott