Hello openui5 team,
This is a suggestion/question from my side.
Currently, we have 4 states for sap.ui.core.ValueState (None, Warning, Error, Success).
Is there any way we can add or customize value state?
For example, we can add a state "In Progress" with text color as blue, and value state text message "The task is in process".
Or customize the 'Warning' state to text color blue.
I tried to google search, then look at the source code, but it seems that there's no easy way to custom like this custom control creating tutorial.
Hence, could you suggest me somehow to customize the value sate, but follow the sapui5 standard as much as possible?
I get lots of request from customers regarding this customization in my sapui5 projects.
Thank you!
Victor.
I cannot suggest anything here. The question is forwarded to dev team for evaluation and check with UX via 1880578419
Hi @strawherotk
the enum sap.ui.core.ValueState (None, Warning, Error, Success) is used in different ways across the framework. Therefore, I would not recommend you to modify this enum (also not supported).
If you just want to change a text color, you could make use of a custom theme
(https://openui5.hana.ondemand.com/#/topic/497c27a8ee26426faacd2b8a1751794a).
If that's not sufficient for your scenario, you would have to create your own control, which is able to handle your custom value states.
Hi @clemai ,
Thanks for the update.
I agree with your suggestion regarding usage of ValueState.
Regards,
Victor.
Hi @strawherotk ,
FYI, a new ValueState with name 'Information' was introduced with:
7371695ce3800e61dab88be68f547a9a3924e9c6
66d788ecf0a90fdb56153ffb4805ca5e55ce0c6e
Hi @clemai,
That's great.
Thanks for the update.
A little pity that the new value state 'information' is the same color with warning state.
I think it would be better to have Blue color instead. :)
Anyway great work!
@strawherotk The "Information" value state is Blue in the current sap_belize* theme.
Source: https://openui5nightly.hana.ondemand.com/#/sample/sap.m.sample.InputValueState/preview
Hi boghyon,
It look great :)
Thanks for the updates.
Most helpful comment
@strawherotk The
"Information"value state is Blue in the currentsap_belize*theme.